Skip to main content
LearnMLAcademy
Advanced10 min read

ML, Statistics & Model Evaluation Interview Questions

Ace machine learning interviews with top 100 solved theory and math questions, with Python code, architecture diagrams, worked examples, and interview quiz.

What you will master in this lesson
Intuitive core mechanisms & practical real-world intuition
Step-by-step mathematical breakdown & visual diagrams
Runnable Python implementation & practical trade-offs

Machine-learning interviews rarely reward a definition by itself. A useful answer connects the concept to assumptions, evidence, a practical decision, and a failure mode.

This 2026-expanded bank covers the durable ML fundamentals plus applied questions that recur in big-tech interviews: imbalance, calibration, experimentation, recommender cold start, feature interpretation, offline-versus-online gaps, and launch decisions.

UPDATED FOR 20269 current big-tech signals moved to the top

This is the expanded interview-preparation version

Current, research-driven questions are shown first so you can immediately see what changed. Each question keeps the detailed answer, example, likely follow-up, and weak-answer warning.

23
detailed interview questions

What you will be able to do

  • Answer ML questions in layers
  • Calculate and interpret common metrics
  • Compare algorithms from their assumptions
  • Recognize leakage and validation defects
  • Diagnose practical model failures

Build an interview answer in layers

Lead with the answer, then add depth when invited

Direct answer
Plain-language intuition
Decision criteria
Example / calculation
Limitation + follow-up
How to read it: A concise first layer prevents rambling; examples, trade-offs, and follow-ups demonstrate genuine understanding.

Choose a metric from the cost of errors

Which mistake is more costly?

Rare positive class
False negative costly
Recall / PR-AUC
False positive costly
Precision
Both matter
F1 + operating point
Probability decisions
Calibration
How to read it: Class balance and decision cost determine the metric; accuracy is not a safe default.

A reusable answer method

Lead with a direct interview-ready answer. Then explain the intuition, name the assumption or decision criterion, use a small example, and close with one limitation or likely follow-up. The interviewer can stop you after any layer without losing the main answer.

Metric and algorithm reminders

Choose from the decision, not from habit

Choose from the decision, not from habit
QuestionUseful starting pointWhat to verify
Rare positive classPrecision, recall, PR-AUCCost of false positives and false negatives
Probability used for actionCalibration plus threshold utilityReliability by score band and segment
Continuous targetMAE or RMSEOutliers and business error units
Tabular baselineLinear/logistic model or treesNon-linearity, scaling, interpretability, latency
ClustersK-means or density methodScale, geometry, stability, business usefulness

23 interview questions with detailed answers

The 9 questions marked 2026 SIGNAL are shown first because they reflect current public big-tech interview patterns. Core fundamentals follow after them.

START HERE2026 high-priority questions

These were added or elevated from the latest research pass. They are intentionally placed before the older core bank so the update is visible immediately.

QUESTION 12026 SIGNALWhether you connect imbalance to decision cost rather than reaching for one technique.

Common big-tech ML pattern: imbalance, thresholds, and business cost are frequent follow-ups in applied-model questions.

How do you handle a highly imbalanced classification problem?

INTERVIEW-READY ANSWER

Start with a metric and operating point that reflect the minority-class decision cost, then compare class weighting, threshold tuning, resampling, better features, and calibrated probabilities under the same validation design.

DEEPER EXPLANATION

Resampling changes the training distribution, not the real prevalence. Class weights change the loss. Threshold tuning changes the decision policy. For rare events, PR-AUC, recall at fixed precision, or recall under a review-capacity constraint are often more informative than accuracy.

Example or calculation: If fraud prevalence is 0.2%, a model predicting no fraud is 99.8% accurate but useless. A better evaluation might require at least 80% precision and then maximize recall within the fraud team's review capacity.
Likely follow-up: When can SMOTE make validation misleading?
Weak answer to avoid: Saying 'use SMOTE' before defining the metric, split, prevalence, and production threshold.
QUESTION 22026 SIGNALSeparating ranking quality from probability quality.

Frequently tested in senior ML and production interviews because many real systems consume scores as probabilities.

What is probability calibration, and why can a high-AUC model still be badly calibrated?

INTERVIEW-READY ANSWER

AUC asks whether positives tend to rank above negatives; calibration asks whether predicted probabilities match observed frequencies. A model can rank perfectly but systematically output probabilities that are too high or too low.

DEEPER EXPLANATION

Calibration matters when probabilities drive pricing, capacity, risk, or intervention thresholds. Reliability diagrams, Brier score, and held-out Platt scaling or isotonic regression can diagnose and repair it without contaminating the final test set.

Example or calculation: Among cases scored near 0.8, a calibrated model should see roughly 80% positives over time. If only 55% are positive, the ranking may still be strong while the probabilities are overconfident.
Likely follow-up: Would you calibrate before or after choosing the threshold?
Weak answer to avoid: Treating ROC-AUC as proof that the probability values themselves are trustworthy.
QUESTION 32026 SIGNALExperiment design plus production judgment.

Google and Meta data/ML interview reports repeatedly emphasize experiments, product metrics, and offline-versus-online evaluation.

How would you launch a new model with an A/B test?

INTERVIEW-READY ANSWER

Define the unit of randomization, primary business metric, guardrails, sample-size or power plan, ramp strategy, and logging before exposing users. Compare treatment against the current policy and keep the model version and assignment stable.

DEEPER EXPLANATION

Offline metrics are necessary but not sufficient because user behavior, latency, feedback loops, and intervention effects appear only online. Avoid interference when users affect one another, and watch novelty effects and repeated peeking.

Example or calculation: For a feed ranker, randomize by user, track long-term engagement as the primary metric, latency and complaint rate as guardrails, start with a small canary, then ramp after data-quality checks.
Likely follow-up: What if the offline NDCG improves but the online engagement metric drops?
Weak answer to avoid: Randomizing requests independently when users need a consistent experience or when interference invalidates the estimate.
QUESTION 42026 SIGNALUnderstanding distribution shift, objective mismatch, and feedback effects.

A recurring system-design follow-up in ranking and recommendation interviews.

Why can offline metrics improve while online product metrics get worse?

INTERVIEW-READY ANSWER

Offline evaluation can optimize the wrong proxy, use a nonrepresentative sample, miss latency or UX costs, or ignore how the new policy changes future data.

DEEPER EXPLANATION

Check data freshness, eligibility, position bias, serving parity, threshold policy, slice performance, and whether the offline label actually represents the business goal. Online systems also create feedback loops that static datasets do not capture.

Example or calculation: A recommender raises offline click prediction AUC but shows repetitive content, reducing session length. The model predicts clicks better while harming the broader product objective.
Likely follow-up: How would you decide whether to rollback immediately or continue the experiment?
Weak answer to avoid: Assuming the online test is wrong because the offline benchmark was higher.
QUESTION 52026 SIGNALTurning model output into an operating policy.

Common applied-ML follow-up after confusion-matrix, calibration, or fraud questions.

How do you choose a decision threshold from a probability score?

INTERVIEW-READY ANSWER

Choose the threshold using expected cost, capacity, or a required precision/recall constraint on validation data; do not default to 0.5.

DEEPER EXPLANATION

The best threshold depends on prevalence, calibration, business cost, and resource limits. Revisit it when those change. If actions are capacity-limited, ranking and top-k selection may be more natural than a single global threshold.

Example or calculation: If manual review can handle 5,000 transactions per day, choose the highest-scoring 5,000 or the threshold that approximates that volume while meeting a minimum precision.
Likely follow-up: What happens if fraud prevalence doubles next month?
Weak answer to avoid: Saying binary classifiers naturally use 0.5 because probabilities below it are negative.
QUESTION 62026 SIGNALInterpretability plus statistical caution.

Project deep-dives often probe whether candidates can explain model behavior responsibly.

How would you explain feature importance without overstating causality?

INTERVIEW-READY ANSWER

Feature importance explains how a fitted model uses information for prediction; it does not establish that changing the feature will cause the outcome to change.

DEEPER EXPLANATION

Tree gain can favor high-cardinality features, permutation importance can be diluted by correlated substitutes, and SHAP values explain predictions relative to a background distribution. Always pair importance with stability checks, leakage review, and domain interpretation.

Example or calculation: If 'number of support calls' has high SHAP magnitude in a churn model, it may reflect customer difficulty or customer engagement. The model cannot tell you whether forcing more calls would reduce churn.
Likely follow-up: How would correlated features change permutation importance?
Weak answer to avoid: Calling the top SHAP feature the most important causal driver.
QUESTION 72026 SIGNALPractical model selection and trade-offs.

Recent Apple and Meta ML question banks explicitly include Random Forest explanations and tree-ensemble comparisons.

Random Forest or gradient boosting: how do you choose?

INTERVIEW-READY ANSWER

Random Forest averages many independent trees for robust low-tuning baselines; gradient boosting builds trees sequentially to correct residual errors and often wins on tabular accuracy but is more sensitive to tuning and leakage.

DEEPER EXPLANATION

Compare under the same split and metric. Consider latency, calibration, class weighting, missing-value handling, interpretability, training cost, and how much tuning the team can operate.

Example or calculation: For churn, start with logistic regression and Random Forest as baselines, then compare boosted trees. If boosting improves lift only slightly but doubles latency and maintenance complexity, the forest may be the better production choice.
Likely follow-up: Why can boosting overfit noisy labels?
Weak answer to avoid: Choosing XGBoost automatically because it is popular.
QUESTION 82026 SIGNALWhether you distinguish new users, new items, and sparse-feedback regimes.

Recommendation and ranking systems are repeatedly reported in Meta, Netflix, Google, and Amazon ML loops.

How do you handle cold start in a recommendation system?

INTERVIEW-READY ANSWER

Use content and context features, popularity or editorial priors, onboarding signals, exploration, and fast feedback collection until collaborative signals become reliable.

DEEPER EXPLANATION

New-user and new-item cold start are different. New items can borrow content embeddings; new users can use context, declared interests, regional trends, or diversified exploration. Measure the transition from prior-based to personalized ranking.

Example or calculation: A new video can be represented from title, creator, topic, and multimodal embeddings, then receive controlled exploratory impressions so watch and skip signals accumulate.
Likely follow-up: How do you explore without degrading user experience?
Weak answer to avoid: Saying collaborative filtering alone solves cold start.
QUESTION 92026 SIGNALProduction-statistics judgment.

Production MLE interviews frequently probe drift, retraining criteria, and delayed-label reasoning.

What is covariate shift, and when should you retrain?

INTERVIEW-READY ANSWER

Covariate shift means the input distribution changes; it does not automatically mean the mapping from inputs to outcomes changed. Retrain only when trustworthy evidence shows the current model no longer meets the decision objective and a candidate improves it safely.

DEEPER EXPLANATION

Monitor feature distributions, score distributions, slices, delayed labels, and business outcomes. A changed input mix may be harmless if the conditional relationship is stable, while concept drift can hurt quality even with small marginal feature changes.

Example or calculation: Holiday traffic changes product mix and age distribution. That raises drift metrics, but if calibrated performance by slice remains stable, an automatic retrain may add risk without benefit.
Likely follow-up: How would you monitor drift when labels arrive 30 days later?
Weak answer to avoid: Triggering retraining whenever PSI crosses one global threshold.
QUESTION 10Whether you distinguish center from spread and check distribution shape.

What do mean and variance tell you, and what can they hide?

INTERVIEW-READY ANSWER

The mean estimates a center; variance averages squared distance from that mean. Neither describes skew, multimodality, or outliers by itself.

DEEPER EXPLANATION

Squaring makes variance sensitive to extreme observations. Median and IQR may be more representative for skewed income or latency data, while segments can reveal two populations hidden by one average.

Example or calculation: For [2, 2, 2, 10], mean = 4 and population variance = ((−2)²×3 + 6²)/4 = 12. The mean is not a value most observations resemble.
Likely follow-up: When would you report a confidence interval around the mean?
Weak answer to avoid: Saying the mean is the ‘typical’ value without inspecting the distribution.
QUESTION 11Base-rate reasoning rather than formula recall.

Explain conditional probability and Bayes' rule with a screening test.

INTERVIEW-READY ANSWER

Bayes updates a prior probability after observing evidence: P(A|B)=P(B|A)P(A)/P(B). A strong test can still have a low positive predictive value when the condition is rare.

DEEPER EXPLANATION

Sensitivity and specificity describe test behaviour conditional on disease state; the patient needs P(disease|positive), which also depends on prevalence.

Example or calculation: Among 1,000 people at 1% prevalence, 90% sensitivity finds 9 true positives. At 95% specificity, about 49.5 healthy people test positive, so only about 9/(9+49.5)=15.4% of positives are true cases.
Likely follow-up: How would prevalence shift affect the operating threshold?
Weak answer to avoid: Confusing P(positive|disease) with P(disease|positive).
QUESTION 12Whether you avoid a common interpretation error.

What does a 95% confidence interval mean?

INTERVIEW-READY ANSWER

Under repeated identical sampling, 95% of intervals produced by the method would contain the fixed population parameter.

DEEPER EXPLANATION

For one computed frequentist interval, the parameter is not randomly moving. Width depends on sample size, variability, and assumptions. A narrow interval can still be biased by bad sampling.

Example or calculation: An accuracy estimate of 0.80 with approximate standard error 0.02 gives 0.80 ± 1.96×0.02, or about [0.761, 0.839].
Likely follow-up: What changes when examples are correlated by user?
Weak answer to avoid: Claiming there is a 95% probability that this fixed parameter lies in this realized interval.
QUESTION 13Statistical reasoning and practical significance.

Explain p-values and hypothesis-test errors.

INTERVIEW-READY ANSWER

A p-value is the probability of data at least this extreme assuming the null is true; it is not the probability that the null is true. Type I is a false positive, Type II a false negative.

DEEPER EXPLANATION

The significance level controls long-run Type I error under assumptions. Power is the chance to detect a chosen real effect. Large samples can make tiny, commercially irrelevant effects statistically significant.

Example or calculation: A conversion gain from 2.50% to 2.58% may produce p=0.03 at high volume, yet shipping still depends on effect size, cost, guardrails, and confidence interval.
Likely follow-up: How would multiple comparisons change your decision?
Weak answer to avoid: Interpreting p=0.03 as a 97% chance the treatment is better.
QUESTION 14Understanding that prediction and intervention ask different questions.

Correlation is not causation—why does that matter to an ML model?

INTERVIEW-READY ANSWER

A model can exploit association without identifying what causes the outcome. Changing a correlated feature may not change the target and may break the historical relationship.

DEEPER EXPLANATION

Confounding, selection, and reverse causality can produce stable-looking correlations. Predictions can still be useful, but intervention claims need experiment or causal assumptions.

Example or calculation: Support calls may correlate with lower churn because engaged customers call. Forcing every customer to call does not necessarily reduce churn.
Likely follow-up: How could an A/B test help?
Weak answer to avoid: Treating feature importance as causal effect.
QUESTION 15Whether you can choose an intervention from evidence.

Explain bias versus variance and diagnose each from learning curves.

INTERVIEW-READY ANSWER

High bias underfits: training and validation error remain high. High variance overfits: training error is low while validation error is much higher.

DEEPER EXPLANATION

More data often narrows a variance gap but usually cannot repair a model whose representational bias keeps both curves poor. Regularization trades some training fit for stability.

Example or calculation: Train error 5% and validation 22% suggests variance; 24% and 26% suggests bias. The first invites more data or regularization; the second better features or a more suitable model.
Likely follow-up: What if both metrics are good but the business KPI fails?
Weak answer to avoid: Assuming more data fixes every generalization problem.
QUESTION 16Ability to preserve prediction-time reality.

What is data leakage, and how do you prevent it?

INTERVIEW-READY ANSWER

Leakage occurs when training uses information unavailable at the real prediction time. Split first and fit every learned transformation only on training data or inside cross-validation folds.

DEEPER EXPLANATION

Leakage can come from future events, target-derived columns, the same entity in train and test, preprocessing on all rows, or a random split for time data.

Example or calculation: A loan-default feature named ‘restructured_later’ reveals the future outcome. Scaling the full dataset before splitting also leaks test-set statistics.
Likely follow-up: Which group or time split would match this product?
Weak answer to avoid: Looking only for an explicit target column and ignoring temporal or entity leakage.
QUESTION 17Matching validation to deployment.

How do you choose cross-validation strategy?

INTERVIEW-READY ANSWER

Use ordinary or stratified folds for independent rows, group folds when entities repeat, and forward time splits when predictions concern the future.

DEEPER EXPLANATION

The validation design should reproduce the independence, chronology, labels, and distribution of production decisions. Nested validation may be needed to estimate performance after hyperparameter tuning.

Example or calculation: Randomly splitting transactions lets one customer's behaviour appear in both sets; grouping by customer measures generalization to unseen customers.
Likely follow-up: When is a single holdout preferable?
Weak answer to avoid: Using shuffled k-fold for every dataset.
QUESTION 18Connection between penalties, weights, and feature behaviour.

How do L1 and L2 regularization differ?

INTERVIEW-READY ANSWER

L1 adds λΣ|w| and can set coefficients exactly to zero; L2 adds λΣw² and smoothly shrinks large coefficients.

DEEPER EXPLANATION

L1 can select among redundant features unstably, while L2 tends to share weight across correlated predictors. Elastic Net combines both.

Example or calculation: With w=3 and λ=0.1, the L2 penalty is 0.9 and its gradient contribution is 0.6; L1 penalty is 0.3 with contribution 0.1 away from zero.
Likely follow-up: Why must features usually be scaled first?
Weak answer to avoid: Claiming L1 always finds the true causal features.
QUESTION 19Model selection from data and constraints.

Compare linear/logistic models, trees, random forests, and boosting.

INTERVIEW-READY ANSWER

Linear models are fast and interpretable under linear structure; trees capture interactions; forests average unstable trees; boosting sequentially corrects residual errors and is often strong on tabular data.

DEEPER EXPLANATION

Choose using data size, non-linearity, missingness, latency, calibration, interpretability, and validation—not a universal ranking.

Example or calculation: Start churn prediction with logistic regression. If interaction-rich tabular patterns remain, compare calibrated gradient boosting under the same split and cost metric.
Likely follow-up: Why might the simpler model still ship?
Weak answer to avoid: Saying boosting is always best because it won a benchmark.
QUESTION 20Geometry, scaling, and dimensionality.

When do kNN, SVM, clustering, and PCA become fragile?

INTERVIEW-READY ANSWER

Distance-based methods need meaningful scaled distances; high dimensions make neighborhoods sparse. PCA is a linear projection that may remove predictive low-variance directions and reduces interpretability.

DEEPER EXPLANATION

kNN also has inference cost proportional to stored examples; kernel SVMs can scale poorly; k-means assumes centroid-like clusters and a chosen k.

Example or calculation: If salary ranges to millions while age ranges to tens, unscaled Euclidean distance is almost entirely salary. Standardize inside the training pipeline before geometry-based methods.
Likely follow-up: When would DBSCAN replace k-means?
Weak answer to avoid: Using a pretty two-dimensional PCA plot as proof that clusters are real.
QUESTION 21Metric calculation plus decision interpretation.

Calculate precision, recall, F1, and accuracy from a confusion matrix.

INTERVIEW-READY ANSWER

Precision=TP/(TP+FP), recall=TP/(TP+FN), F1=2PR/(P+R), and accuracy=(TP+TN)/all examples.

DEEPER EXPLANATION

The operating threshold trades false positives against false negatives. PR-AUC summarizes ranking under rare positives; calibration asks whether a stated probability is reliable.

Example or calculation: TP=40, FP=10, FN=20, TN=930 gives precision 40/50=0.80, recall 40/60=0.667, F1≈0.727, and accuracy 970/1000=0.97. Accuracy hides 20 missed positives.
Likely follow-up: Which operating point fits fraud review capacity?
Weak answer to avoid: Choosing the metric before understanding the decision cost.
QUESTION 22Separating ranking, probability quality, and operating decisions.

When use ROC-AUC, PR-AUC, calibration, or a fixed-threshold metric?

INTERVIEW-READY ANSWER

ROC-AUC measures ranking across thresholds, PR-AUC emphasizes positive-class retrieval, calibration measures probability reliability, and threshold metrics measure the chosen operating policy.

DEEPER EXPLANATION

A model can rank well but be poorly calibrated, or have better AUC yet worse recall at the only threshold the business can use.

Example or calculation: For 0.1% fraud, PR-AUC and recall at a review-capacity precision are often more informative than accuracy or ROC-AUC alone.
Likely follow-up: How would you calibrate a score without contaminating the test set?
Weak answer to avoid: Treating AUC as the probability that every prediction is correct.
QUESTION 23A disciplined diagnostic order.

How do you debug poor validation or production degradation?

INTERVIEW-READY ANSWER

Check metric and slice definitions, split integrity, label/data quality, preprocessing parity, feature drift, version changes, and service behaviour before changing algorithms or retraining.

DEEPER EXPLANATION

Reproduce one prediction end to end. Compare current and reference data, features, scores, threshold, latency, and delayed labels. Separate ranking drift from threshold or calibration drift.

Example or calculation: Recall falls sharply while ROC-AUC barely changes: inspect score distribution, calibration, and threshold first; the ranking may still be useful.
Likely follow-up: What evidence would justify rollback versus retraining?
Weak answer to avoid: Jumping directly to a larger model or ‘just retrain.’

Use these links when an interview question exposes a gap. The interview guide focuses on explanation and decision-making; the linked lesson teaches the full concept.

Keep the answer honest: role boundaries, interview processes, and project outcomes vary. Never invent experience, impact, salary, or certainty to make an answer sound stronger.

Summary / Key Takeaways

  • Interview-ready answers connect a direct response to assumptions, examples, and limitations.
  • Statistics questions test interpretation of uncertainty, base rates, experiments, and causal claims.
  • Leakage prevention requires prediction-time thinking, correct splits, and training-only preprocessing.
  • Bias and variance diagnostics determine whether capacity, regularization, or more data is likely to help.
  • Algorithm choice depends on geometry, scale, interpretability, latency, and validated performance.
  • Metric choice must reflect class balance, probability use, threshold policy, and error cost.
  • Production degradation should be localized with evidence before rollback, repair, or retraining.

Apply this concept in a real hands-on project

You have studied the idea. Now use it in working Python code, see the calculation and output, and explain what changed. Each project includes step-by-step instructions, full source and tests.

Practice challenge: predict an outcome first, run the code, and explain the difference.

Track Your Progress0% curriculum done

Finished "ML, Statistics & Model Evaluation Interview Questions"?

Mark this lesson as completed to update your progress bar and track your milestones across the full curriculum.

Overall Progress0 / 167 lessons

Was this tutorial helpful?

Your feedback helps us continuously refine and improve our open-access tutorials.

Knowledge Check

Progress: 0/5

Test your active recall. Choose one answer for each question, then check it to reveal the step-by-step reasoning.

Question 1 of 5numerical/formula
TP=40, FP=10, FN=20. What is recall?
Question 2 of 5debugging/diagnostic
Training error is low and validation error is high. What is the leading diagnosis?
Question 3 of 5application/scenario
Which feature is leakage when predicting default at loan approval?
Question 4 of 5interpretation
A screening test has high sensitivity but the condition is rare. What must be considered before interpreting a positive?
Question 5 of 5practical selection
For 0.1% fraud, which metric is often more informative than accuracy?

Knowledge Check Review & Explanations

Review the questions, verified correct answers, and conceptual explanations for this lesson.

1TP=40, FP=10, FN=20. What is recall?▼

Correct Answer: 0.667

Recall=TP/(TP+FN)=40/60≈0.667. Precision would be 40/50=0.80.

2Training error is low and validation error is high. What is the leading diagnosis?▼

Correct Answer: High variance

A large generalization gap indicates the model fits training examples much better than unseen validation examples.

3Which feature is leakage when predicting default at loan approval?▼

Correct Answer: Restructuring recorded after default risk emerged

A later restructuring event is not available at the original prediction time and may reveal the outcome.

4A screening test has high sensitivity but the condition is rare. What must be considered before interpreting a positive?▼

Correct Answer: Base rate or prevalence

Bayes' rule shows that positive predictive value depends strongly on prevalence as well as sensitivity and specificity.

5For 0.1% fraud, which metric is often more informative than accuracy?▼

Correct Answer: PR-AUC

PR-AUC focuses on retrieving the rare positive class and the precision/recall trade-off.

Keep moving through the path

Continue Learning

Free Download: ML Interview Cheatsheet

100 essential Machine Learning interview questions and answers covering foundations, algorithms, evaluation, deep learning, Python, system design and interview strategy. Enter your email to download it instantly.

Next