Interview Questions

The Data Science Interview Questions That Actually Trip People Up

By Hari June 3, 2026
The Data Science Interview Questions That Actually Trip People Up

Data science interviews changed a lot between 2022 and now. Specifically, the ones that used to start with whiteboard statistics have shifted toward product case questions, ambiguous metric design, and “tell me how you’d ship this model” discussions. I’m not saying the statistics is gone. It isn’t. But the order and weighting are different than what most prep guides describe.

I work on the team at LastRound AI that builds the interview copilot software. We see a lot of live data science interview rounds. And the pattern that shows up most is this: candidates who’ve memorized the textbook answers to data science interview questions still fail when the interviewer asks a follow-up that goes one level deeper. The person who can explain bias-variance tradeoff perfectly gets stuck the moment the interviewer asks, “OK, so given that, which would you actually pick here, and why?” The answer requires judgment, not recall.

The BLS projects data scientist employment to grow 34% between 2024 and 2034, with a median annual wage of $112,590 and roughly 23,400 new openings per year according to the Occupational Outlook Handbook. The field is growing fast. The interview bar is moving up with it.

Python is used by 51% of developers in the 2024 Stack Overflow Developer Survey, and scikit-learn shows up at 10.6% overall, which understates its use among working data scientists. These aren’t just nice-to-know facts. Interviewers at companies like Snowflake, Databricks, and most of the major tech shops will assume Python fluency and will test whether you know which sklearn estimator to actually reach for, not whether you can spell “gradient boosting.”

What this post covers

  • SQL and data wrangling – the most consistently tested area across all interview levels
  • Statistics and experimentation – A/B testing design is asked at nearly every mid-level and above round
  • Machine learning concepts – theory plus the follow-up judgment questions that trip people up
  • Product and case questions – senior rounds are 60-70% this, not ML theory
  • What I’d actually prioritize if prepping for a round next week

SQL and Data Manipulation

SQL is the most tested skill in data science interviews. I’d say this is almost unfair if not for the fact that it’s also the most used skill on the job. If you’re rusty, start here. Window functions in particular come up in 7 out of 10 mid-level rounds in what I’ve seen. Not once or twice. Consistently.

Entry-level SQL questions

  1. 1. Write a query to find the second-highest salary from an employee table.

    Tests LIMIT, ORDER BY, and subqueries. The gotcha: interviewers sometimes want DENSE_RANK instead of LIMIT 1 OFFSET 1, because of ties. Ask which behavior they want before writing.

  2. 2. What’s the difference between INNER JOIN and LEFT JOIN?

    Know this cold. The follow-up is usually “when would you pick a LEFT JOIN for a business metric calculation?” – which trips up people who only know the textbook definition.

  3. 3. How do you handle NULL values in SQL?

    COALESCE vs ISNULL, how NULLs affect COUNT vs COUNT(*), and the filter-vs-replace tradeoff are all fair game here.

  4. 4. Find duplicate records in a table.

    GROUP BY with HAVING COUNT(*) > 1. Then the natural follow-up: how do you delete all but one copy? That’s where ROW_NUMBER() OVER (PARTITION BY …) comes in.

  5. 5. Calculate a running total using SQL.

    SUM(…) OVER (ORDER BY …) is what they want. If you reach for a self-join, you’ll probably get a polite redirect.

Mid-level SQL questions

  1. 6. Write a query to calculate customer churn rate month over month.

    This combines date functions, cohort logic, and window functions. Clarify the churn definition first. At most companies, “churned” isn’t binary.

  2. 7. How would you speed up a slow SQL query?

    EXPLAIN ANALYZE, index strategy, avoiding full table scans, and whether you should materialize an intermediate result. The interviewer is checking whether you actually debug queries or just write them.

  3. 8. Write a query for retention cohort analysis.

    Group users by signup week, then calculate what % returned in weeks 1, 2, 4. This is a 15-minute exercise and a reasonable bar for mid-level. Practice it timed.

  4. 9. Get the top 3 products by revenue in each category.

    RANK() vs DENSE_RANK() vs ROW_NUMBER() and when ties change the answer. Classic window function test.

  5. 10. Calculate month-over-month growth rate.

    LAG() over a month partition. Then follow-up: what if there are months with no data? Handling gaps in a time series is the actual skill being tested.

Senior-level SQL and data architecture questions

  1. 11. Design a data warehouse schema for an e-commerce analytics platform.

    Star schema with fact_orders and dimension tables for product, user, date. The tricky part: modeling promotions and returns without exploding row count.

  2. 12. How do you handle slowly changing dimensions?

    SCD Type 2 (add effective_date + expiry_date) is the standard answer. SCD Type 1 is fine when history doesn’t matter. Knowing when to pick which is what they’re really testing.

  3. 13. How would you implement incremental data loading into a warehouse?

    Change data capture via updated_at watermarks or CDC tools like Debezium. The failure modes matter: what happens if a record is updated but the watermark doesn’t move?

Statistics and Experimentation

This is the area where I see the widest gap between “knows it on paper” and “can apply it under pressure.” A/B test design questions in particular. Everyone can say “you need sufficient sample size.” Almost nobody, in the moment, correctly identifies when running a test is actually the wrong answer.

For what it’s worth: I think the p-value question is overused in interviews. It’s a fine signal of whether someone has taken an intro stats course. It tells you almost nothing about whether they can run an experiment without making four common errors along the way. That’s my opinion and I’d guess 40% of data science hiring managers would disagree with me.

Core statistics questions

  1. 14. What’s the difference between mean, median, and mode, and when does the choice matter?

    The “when does the choice matter” part is what they want. Skewed salary distributions, bimodal user-session lengths. Give a real example.

  2. 15. Explain the Central Limit Theorem in plain terms.

    The distribution of sample means approaches normal as n grows, regardless of the underlying distribution. Why it matters: it’s the justification for using t-tests on real-world, non-normal data.

  3. 16. What does a p-value actually tell you?

    Probability of observing this result (or more extreme) if the null hypothesis were true. Common mistake: saying it’s the probability the null is true. They’re different things.

  4. 17. How do you detect outliers in a dataset?

    IQR fences, z-scores, isolation forests for higher dimensions. The harder question: how do you decide whether an outlier is a data error vs a real signal?

  5. 18. Explain the difference between correlation and causation. Give an example where they diverge.

    Ice cream sales and drowning rates correlate. Both go up in summer. Neither causes the other. The interviewer wants to know you’d think about confounders before recommending action.

A/B testing and experimentation questions

  1. 19. How would you design an A/B test for a new checkout flow?

    Randomization unit (user vs session), minimum detectable effect, power calculation, guardrail metrics. In a real round, walk through each step. Don’t skip straight to “run it for two weeks.”

  2. 20. What’s the difference between Type I and Type II error? Which matters more?

    False positive vs false negative. “Which matters more” is domain-dependent. In fraud detection, Type II (missing a fraud) is usually worse. In a checkout A/B test, you might care more about Type I (shipping a bad change). Show that you know it depends.

  3. 21. How do you handle multiple hypothesis testing?

    Bonferroni is conservative. Benjamini-Hochberg FDR correction is more common in practice. Know when to pre-register your hypotheses vs post-hoc correction.

  4. 22. How would you run an experiment when users are connected to each other?

    Network effects invalidate standard randomization. Cluster-level randomization (by school, region, or social graph component) is the usual workaround. This comes up in marketplace and social product interviews specifically.

  5. 23. What’s Bayesian vs frequentist experimentation?

    Frequentist: p-value and confidence interval, interpret at fixed sample. Bayesian: update prior with data, express uncertainty as a distribution, can stop early with valid interpretation. Most tech companies use frequentist in practice but Bayesian is gaining ground in sequential testing contexts.

Machine Learning

The ML section of a data science interview varies the most across companies. At some places it’s 30 minutes of theory. At others it’s “walk me through the last model you built in production.” For senior roles, it’s almost always the latter. If you’ve spent all your prep time on theory and you’re applying for a senior position, you’re over-indexed on the wrong thing.

ML fundamentals

  1. 24. What’s the difference between supervised and unsupervised learning?

    Supervised: labeled targets, learn a mapping. Unsupervised: find structure without labels. Self-supervised is a third category worth knowing in 2026, given how central it is to foundation models.

  2. 25. Explain bias-variance tradeoff.

    High bias = model too simple, misses patterns. High variance = model too complex, memorizes training data. Regularization, cross-validation, and ensemble methods all sit on this axis. The follow-up is always “so given this dataset, which would you worry about more?”

  3. 26. How do you evaluate a classification model?

    Accuracy is almost always the wrong primary metric. Precision and recall depend on the cost of each error type. F1 is a harmless default. ROC-AUC when threshold selection matters. PR-AUC when the dataset is imbalanced.

  4. 27. What’s cross-validation, and when does k-fold break down?

    K-fold breaks down with time-series data because future data leaks into training folds. Use time-series split instead. This is a detail that separates candidates who’ve shipped models from those who’ve only studied them.

  5. 28. What are the assumptions of linear regression?

    Linearity, independence of errors, homoscedasticity, normality of residuals. The follow-up: how would you diagnose a violation? Residuals plot, Durbin-Watson test, variance inflation factor.

Mid-level ML questions

  1. 29. How do you handle class imbalance?

    SMOTE, class weights, undersampling majority, threshold adjustment. The choice depends on whether you have 5% minority class or 0.01%. At extreme imbalance, anomaly detection framing often beats classification.

  2. 30. What’s the difference between Random Forest and Gradient Boosting? When do you pick each?

    Random Forest: parallel, bagging, lower variance. Gradient Boosting: sequential, lower bias, more hyperparameters to tune. XGBoost/LightGBM are the default choice for tabular data in production. Random Forest wins when you need faster training or more interpretability at the tree level.

  3. 31. How do you select features for a model?

    Correlation analysis, recursive feature elimination, LASSO as embedded selection, or SHAP values after training. Mention the leakage risk: features that are proxies for the target in training data but won’t be available at inference time.

  4. 32. Explain L1 vs L2 regularization.

    L1 (Lasso) drives some coefficients to exactly zero – sparse model. L2 (Ridge) shrinks all coefficients toward zero – stable model. Elastic net combines both. Pick L1 when you suspect only a subset of features matter.

  5. 33. How would you build a basic recommendation system from scratch?

    Collaborative filtering (matrix factorization or item-item similarity) vs content-based (feature similarity). Cold start problem for new users/items is the real challenge. Most production systems use a hybrid with a retrieval stage plus a ranking stage.

Senior-level ML and production questions

  1. 34. How do you deploy an ML model to production?

    Model registry (MLflow, SageMaker), containerized inference endpoint, shadow mode before full rollout, feature store if you’re sharing features across models. The real question is about observability: how do you know the model is behaving correctly after deployment?

  2. 35. What’s model drift, and how do you detect it?

    Data drift (input distribution shifts) vs concept drift (relationship between inputs and outputs changes). Monitor prediction score distributions, check feature statistics against training baselines, watch downstream business metrics as a lagging signal.

  3. 36. What model interpretability tools do you use?

    SHAP for feature importance with proper game-theory grounding. LIME for local explanations on individual predictions. Partial dependence plots for marginal effects. If you can’t explain why a model made a prediction to a stakeholder, you’ll have trouble getting it shipped at most regulated companies.

  4. 37. Design an ML system for real-time fraud detection.

    Feature engineering on streaming transaction data (Kafka + Flink or similar), low-latency inference endpoint under 50ms, class imbalance strategy, false positive cost vs false negative cost, human review queue for borderline predictions. This is a systems design question as much as an ML question.

Product and Case Questions

Senior data science rounds are increasingly weighted toward these. I’ve seen rounds at mid-size tech companies where the candidate spent 45 of 60 minutes on case questions and maybe 15 minutes on any ML theory. The theory is a bar to clear, not the main event.

  1. 38. Our daily active users dropped 19% last Tuesday. How would you investigate?

    Segment by platform, geography, acquisition channel, user cohort. Check for data pipeline issues before assuming product problems. Look at correlated metrics. Ask whether Tuesday had any deploys, marketing changes, or external events. This is the most common case question format – practice it until the framework is automatic.

  2. 39. How would you define a metric to measure the health of a marketplace?

    Supply-demand balance metrics, liquidity, transaction success rate, repeat purchase rate. There’s no single right answer – the interviewer wants to see whether you can reason about what “healthy” means for the business before picking a number.

  3. 40. How would you prioritize features for the next product quarter using data?

    Expected value (impact x reach x confidence) vs pure intuition. Mention the survivorship bias in using historical data to project future impact. Qualitative signals from user research that don’t show up in quantitative data.

  4. 41. Estimate the revenue impact of a new personalization algorithm.

    A/B test design, lift estimation, causal reasoning about whether the lift generalizes beyond the test period. Watch out for novelty effects in short tests.

  5. 42. How would you explain a gradient boosted model’s output to a CFO?

    Lead with the business output, not the model mechanics. “Given these 7 factors, the model predicts this customer is 3x more likely to churn in the next 30 days.” Then, if they ask how, use a simple analogy – a series of small adjustments based on where previous guesses were wrong. SHAP plots are useful visual aids if the CFO wants to go deeper.

Real-time support during live data science interviews

Blanking on a window function syntax or second-guessing which regularization to recommend? LastRound AI’s interview copilot listens to your interview audio and surfaces relevant hints in real time, without the interviewer seeing anything.

  • SQL query hints and window function reminders
  • Statistics definitions when you need exact wording
  • ML algorithm tradeoffs for follow-up questions
  • Case question frameworks when the prompt is ambiguous

What I’d actually focus on if I had one week

This is my honest take, and I could be wrong about the prioritization for your specific target company. But across what we see in live rounds:

  1. Day 1-2: SQL, specifically window functions. Practice cohort retention queries timed. If you’re not writing ROW_NUMBER/RANK/LAG from memory, you’ll slow down on the thing interviewers watch most closely.

  2. Day 3: One A/B test design exercise end to end. Pick a product you use and design a test for a feature change, including sample size calculation and metric selection. Go through it out loud. The verbal fluency matters as much as the correctness.

  3. Day 4: The DAU drop case question. Practice the diagnosis framework until the first 5 minutes – data validation, segmentation, hypothesis generation – are automatic. This question or a variant of it shows up more than any other single case question type.

  4. Day 5: One ML system design walkthrough. Pick fraud detection or a recommendation system, write out the full pipeline, and practice explaining it to a non-technical audience. If you can’t explain why you chose each component, you’ll get caught by a “why not X instead?” follow-up.

A few things that I genuinely don’t think are worth your time in week-one prep: memorizing the math behind SVMs (unless you’re applying to a research role), re-reading your old ML textbook chapters, and doing more LeetCode. SQL practice and case questions have a much higher return per hour for data science specifically.

For the data engineering overlap – how the role splits between analysis and engineering work – our comparison of data engineering vs data science roles in 2026 covers what’s converging and what’s still distinct. And if you’re moving toward ML engineering or MLOps, we’ve also covered MLOps interview questions and the AI/ML engineer interview guide separately, since those roles test you on different things than a pure data science role.

What we see in live data science rounds

Across data science interview rounds that run through LastRound AI, the questions where candidates most often need a hint aren’t the ML theory questions. They’re the SQL window function questions and the metric design questions – areas that feel straightforward in prep but get harder under time pressure with a specific context. Candidates who’ve done timed SQL practice with real schemas perform noticeably more smoothly in these sections.

Hari

Written by

Hari

Engineering, LastRound AI.

View Hari's LinkedIn profile →

Leave a Reply

Your email address will not be published. Required fields are marked *