Freshworks | Interview (1st Round) | Bengaluru | Data Scientist
- Location
- Bengaluru
- Experience
- 3.5 years
- Posted
- 22 Jun 2025
Summary
I interviewed for a Data Scientist role at Freshworks in January 2025. The first round, a technical round, included two coding questions and several ML/NLP theoretical questions; I was able to discuss the approach for one of the coding problems.
How it went
Interview Context
I appeared for a Data Scientist role at Freshworks in January 2025. I had 3.5 years of industry experience as a Data Scientist in a mid sized company. The first round was a technical round consisting of two coding questions and a set of ML + NLP theoretical questions.
Below are the questions I was asked:
🔹 Q1: Simulate a Two-Die Casino Game
Problem Statement: You are working for a casino and need to simulate a two dice game. Write a function that simulates the sum of rolling two six-sided dice, but you are only allowed to use one random function.
Constraints: • Use only one call to a uniform random function like random.randint(1, 6). • Return values should range from 2 to 12, with correct probability distribution.
Follow up: Avoid multiple calls to random function
🔹 Q2: Maximum Minimum Thickness of Slab
Problem Statement: You’re given an m x n matrix, where each cell holds the thickness of a slab. You need to move from the top-left cell (0, 0) to the bottom-right cell (m-1, n-1), moving only right or down.
The goal is to maximize the minimum thickness encountered along the path.
Input:
[
[5, 1, 7],
[4, 8, 5],
[2, 3, 9]
]
Output: 4
Explanation: Path = [5 → 4 → 8 → 5 → 9], minimum along path = 4
🔹 Recommended Practice (as per HR):
• Number of Islands (Graph traversal / DFS-BFS problem): https://leetcode.com/problems/number-of-islands/description/
🔹 ML / NLP Theory Questions:
- What is a reranker?
- Difference between Bi-Encoder and Cross-Encoder?
- How is BERT different from GPT?
- What are activation functions used for?
- What is regularization and why is it important?
Update:
Second Coding question was not very easy, I could discuss the approach only.
Questions asked (7)
- 01
Simulate a Two-Die Casino Game
Data Structures & Algorithms
Problem Statement: You are working for a casino and need to simulate a two dice game. Write a function that simulates the sum of rolling two six-sided dice, but you are only allowed to use one random function.
Constraints: • Use only one call to a uniform random function like random.randint(1, 6). • Return values should range from 2 to 12, with correct probability distribution.
Follow up: Avoid multiple calls to random function
- 02
Maximum Minimum Thickness of Slab
Data Structures & Algorithms
Problem Statement: You’re given an m x n matrix, where each cell holds the thickness of a slab. You need to move from the top-left cell (0, 0) to the bottom-right cell (m-1, n-1), moving only right or down.
The goal is to maximize the minimum thickness encountered along the path.
Input: [ [5, 1, 7], [4, 8, 5], [2, 3, 9] ] Output: 4 Explanation: Path = [5 → 4 → 8 → 5 → 9], minimum along path = 4 - 03
What is a reranker?
Other
What is a reranker?
- 04
Difference between Bi-Encoder and Cross-Encoder?
Other
Difference between Bi-Encoder and Cross-Encoder?
- 05
How is BERT different from GPT?
Other
How is BERT different from GPT?
- 06
What are activation functions used for?
Other
What are activation functions used for?
- 07
What is regularization and why is it important?
Other
What is regularization and why is it important?