Data Scientist interview questions, and how to answer them

Most data scientist interviews aren't testing whether you know the math. They're testing whether you can take a vague business question, pick a sensible method, and explain the answer to someone who doesn't care about your model. Here's what each round looks for and how to answer the questions that come up again and again.

The process

What happens in each round

  1. 1

    Recruiter screen

    What happens

    Whether your background matches the flavour of data science they hire for. Some teams mean product analytics and experiments, others mean building models that ship. Know which one this is before you get on the call, and describe your work in their terms.

  2. 2

    Technical screen

    What happens

    Live SQL and a bit of Python or R, usually in a shared editor. They watch how you handle joins, window functions, nulls and duplicate rows. Talking through your assumptions out loud matters as much as the final query.

  3. 3

    Statistics and experimentation

    What happens

    Hypothesis testing, confidence intervals, bias and variance, and how you'd design or read an A/B test. Expect follow-ups that poke at the edge cases, like a test that ended early or a metric that moved the wrong way.

  4. 4

    Case or take-home

    What happens

    A product problem or a small dataset with an open question. They're judging your framing, your choice of metric, and whether your write-up leads with the answer instead of the method.

  5. 5

    Hiring manager and behavioural

    What happens

    How you work with product managers and engineers, how you handle a result nobody wanted, and whether you can say no to a request that doesn't need a model.

Questions you're likely to get

1.Walk me through a model or analysis you built that changed a decision.

Why they ask

They want proof your work leaves the notebook. Plenty of candidates have built models. Fewer can point to a decision that went differently because of them.

How to answer

  • Open with the business question and who was asking, in one sentence
  • Say what data you had, what was wrong with it, and how you cleaned it
  • Explain why you chose that method over a simpler one
  • Name the decision that changed and how you know it changed
  • Mention one thing you'd do differently now
2.Write a query that returns each user's most recent order and the order before it.

Why they ask

It's a window function test in disguise. It also shows whether you think about ties, users with a single order, and time zones.

How to answer

  • Use ROW_NUMBER or LAG partitioned by user and ordered by order timestamp
  • Ask how ties on the same timestamp should break, then pick a secondary sort
  • Say what happens to users with only one order and whether they belong in the output
  • Check the result on a couple of users by hand before calling it done
3.We ran an A/B test on a new checkout page. Conversion went up but revenue per user went down. What do you tell the product manager?

Why they ask

Real tests rarely give a clean answer. They want to see you reason about competing metrics instead of declaring a winner.

How to answer

  • Check the test first: sample ratio mismatch, how it was randomized, whether it ran long enough to cover weekly cycles
  • Break revenue down into conversion, order size and item mix to find where the drop lives
  • Look at segments like new versus returning users, but warn about slicing until something looks significant
  • Go back to the primary metric that was agreed before launch
  • Give a recommendation with a clear statement of the risk, not a menu of options
4.Explain a p-value to a product manager who has never taken a statistics class.

Why they ask

You'll spend a lot of your week translating. If you can't explain the basics plainly, your results won't get used.

How to answer

  • Use a plain setup: if the change did nothing, how surprising would this result be
  • Say clearly what it isn't, which is the chance the change works
  • Tie it to their decision: whether the evidence is strong enough to ship
  • Offer the confidence interval as the more useful number for planning
5.How would you build a model to predict which customers will cancel next month?

Why they ask

Churn is the classic take-home. It shows whether you define the target carefully and think about leakage before you touch an algorithm.

How to answer

  • Pin down what cancel means (voluntary, payment failure, downgrade) and the prediction window
  • Build features only from data available before the prediction date, to avoid leakage
  • Start with a logistic regression baseline, then try gradient boosting like XGBoost or LightGBM
  • Pick an evaluation metric that fits an imbalanced class, such as precision at the top of the list or PR AUC
  • Ask what the retention team will actually do with the scores, since that decides the threshold
6.Your model scores well offline but does worse after launch. What do you check?

Why they ask

Every working data scientist has lived this. Your answer shows whether you have.

How to answer

  • Look for leakage in the training data that doesn't exist at prediction time
  • Compare feature distributions between training and live traffic to spot drift
  • Check the pipeline itself: a feature computed differently in production is a common culprit
  • Confirm the live metric matches the offline one in definition and population
  • Set up monitoring so you catch it sooner next time
7.What's the bias-variance tradeoff, and how has it shown up in your own work?

Why they ask

The definition is easy to memorize. The second half of the question is what separates people who've tuned real models.

How to answer

  • Give a short definition: simple models miss patterns, flexible ones chase noise
  • Describe a real case, like a deep tree that nailed training data and fell apart on holdout
  • Say what you did about it: regularization, cross-validation, fewer features, more data
  • Mention how you chose the final setting and why
8.How would you decide whether a new feature in the app is working, if you can't run an experiment?

Why they ask

Plenty of launches can't be randomized. They want to know if you understand causal inference beyond A/B tests.

How to answer

  • Say why a raw before-and-after comparison misleads (seasonality, other launches, who opts in)
  • Suggest a method that fits the setup: difference-in-differences, a staged rollout by region, or matching
  • State the assumption each method depends on and how you'd check it
  • Be honest about how confident the answer can be
9.Tell me about a time your analysis showed something a stakeholder didn't want to hear.

Why they ask

Data scientists who only confirm what leaders already believe aren't worth hiring. They want to see you hold a position without burning the relationship.

How to answer

  • Set the scene briefly: who, what they hoped, what you found
  • Explain how you double-checked before you shared it
  • Describe how you delivered it, ideally in a one-on-one before the big meeting
  • Say what happened next, including if they didn't take your advice
10.A product manager asks you to build a machine learning model for something a simple rule could handle. What do you do?

Why they ask

Knowing when not to build a model is one of the most useful skills in the job. Hiring managers get burned by people who overbuild.

How to answer

  • Ask what decision the model would drive and how often
  • Propose the rule or a simple heuristic as a baseline first
  • Explain the ongoing cost of a model: pipelines, monitoring, retraining
  • Agree on what result would justify the model later
11.How do you handle missing data in a dataset you've just been handed?

Why they ask

It's a basic question that reveals how carefully you work. The right answer starts with asking why the data is missing.

How to answer

  • Find out why it's missing, since a broken logging event is different from a user skipping a field
  • Check whether missingness itself predicts the outcome, and keep it as a flag if so
  • Choose between dropping, simple imputation and model-based imputation based on that
  • Note the choice in your write-up so others can question it
12.Which metric would you pick to measure the health of a food delivery app, and why?

Why they ask

Product sense rounds test whether you understand the business, not only the data. There's no single right metric, so they judge the reasoning.

How to answer

  • Name the parties involved: customers, restaurants, couriers
  • Propose a north star metric, like orders delivered on time per week, and say why
  • Add a few guardrail metrics so you don't win one side by hurting another
  • Mention how you'd spot someone gaming the metric

Mistakes that sink good candidates

Talking about algorithms before you've asked what decision the work supports

Writing SQL in silence

Interviewers can't give you credit for reasoning they can't hear.

Handing in a take-home that opens with methodology and buries the answer on the last page

Claiming a project result you can't explain step by step when they ask a follow-up

Need more Data Scientist interviews to prep for?

HeroApply applies to Data Scientist jobs that match you, every day. 1,860 jobs are open today.

Find Data Scientist jobs