Katkat

practice a little every day, paws crossed ♡

Machine Learning Interview Questions

Practice 9403 coding, system design and machine learning questions from 546 companies, sorted by role, topic and interview round. Every question has step-by-step hints, a code runner that supports 8 languages and an AI mentor; members also get the full solution walkthrough.

9403
Questions
546
Companies
11
Topics
8
Languages

Showing 91–120 of 572 results

  • Boston Consulting GroupMediumData Scientist
    Build a leak-free sklearn pipeline

    This problem tests the ability to build a robust scikit-learn pipeline that prevents data leakage during preprocessing and hyperparameter tuning while handling class imbalance.

    Machine LearningOnline Assessmentscikit-learndata-leakagepipelines
  • Boston Consulting GroupMediumData Scientist
    Build and evaluate imbalanced binary classifier

    This question evaluates a data scientist's skills in building reproducible machine learning pipelines for imbalanced binary classification, covering temporal splitting to avoid leakage, class imbalance handling, feature preprocessing, probability calibration, threshold selection, and monitoring for calibration drift.

    Machine LearningOnline Assessment
  • Boston Consulting GroupMediumData Scientist
    Design and sample for credit default prediction

    This question evaluates a data scientist's competencies in imbalanced binary classification, temporal label definition and leakage detection, sampling and calibration under prior-probability shift, metric and operating-point selection, cost-sensitive decision rules, time-based validation and monitoring, and fairness and operational guardrails.

    Machine LearningTechnical Screen
  • Boston Consulting GroupHardData Scientist
    Detect Data Leakage in Supervised Learning Pipelines

    This interview question evaluates core ML concepts, assumptions, math intuition, training/evaluation trade-offs, and practical failure modes in a realistic interview setting. A strong answer for Detect Data Leakage in Supervised Learning Pipelines states assumptions, handles edge cases, explains trade-offs, and shows how to validate the result clearly.

    Machine LearningOnline Assessment
  • Boston Consulting GroupMediumData Scientist
    Improve Model Generalization with Cross-Validation and Feature Engineering

    This interview question evaluates core ML concepts, assumptions, math intuition, training/evaluation trade-offs, and practical failure modes in a realistic interview setting. A strong answer for Improve Model Generalization with Cross-Validation and Feature Engineering states assumptions, handles edge cases, explains trade-offs, and shows how to validate the result clearly.

    Machine LearningOnline Assessment
  • Boston Consulting GroupHardData Scientist
    Reduce overfitting under constraints

    This question evaluates a candidate's competency in machine learning for mitigating overfitting in tabular regression under production latency constraints, testing knowledge of regularization, model complexity control, feature engineering, validation strategies, and experimental design.

    Machine LearningTechnical Screen
  • Boston Consulting GroupEasyData Scientist
    Scale and Normalize: When to Use Each Method?

    This interview question evaluates core ML concepts, assumptions, math intuition, training/evaluation trade-offs, and practical failure modes in a realistic interview setting. A strong answer for Scale and Normalize: When to Use Each Method? states assumptions, handles edge cases, explains trade-offs, and shows how to validate the result clearly.

    Machine LearningOnline Assessment
  • Boston Consulting GroupEasyData Scientist
    Train GradientBoostingClassifier with 5-Fold Cross-Validation

    This interview question evaluates core ML concepts, assumptions, math intuition, training/evaluation trade-offs, and practical failure modes in a realistic interview setting. A strong answer for Train GradientBoostingClassifier with 5-Fold Cross-Validation states assumptions, handles edge cases, explains trade-offs, and shows how to validate the result clearly.

    Machine LearningOnline Assessment
  • ByteDanceMediumSoftware Engineer
    Choose Precision, Recall, or F1 for Agent Evaluation

    This question tests the ability to map business objectives and error costs to appropriate classification metrics in a real-world system context.

    Machine LearningTechnical ScreenMetricsClassificationModel Evaluation
  • ByteDanceMediumData Scientist
    Choose Ranking Functions, Customer Value Metrics, and Predictive Models

    This problem tests the ability to implement SQL window functions for cohort analysis, define robust customer lifetime value metrics, and articulate the trade-offs between various machine learning algorithms in a production setting.

    Machine LearningTechnical ScreenSQLCustomer-AnalyticsModel-Selection
  • ByteDanceMediumMachine Learning Engineer
    Compute Sentence Similarity

    This question evaluates understanding of sentence-level and token-level embedding techniques, text preprocessing, similarity metrics, edge-case handling for empty or unknown tokens, and trade-offs between pretrained sentence encoders and averaged word embeddings.

    Machine LearningTechnical Screen
  • ByteDanceMediumApplied Scientist
    Explain GRPO for LLM Reinforcement Learning and How It Differs from PPO

    An ML question asking you to explain Group Relative Policy Optimization (GRPO) for fine-tuning large language models with reinforcement learning. It tests your grasp of group-normalized advantages, the clipped objective with a KL penalty, the contrast with PPO and its value model, and common failure modes.

    Machine LearningTechnical Screen
  • ByteDanceMediumMachine Learning Engineer
    Explain LLM generational improvements, multimodal LLMs, and normalization in LLMs

    Three conceptual LLM questions: the main improvements across generations of a model family as described in technical reports, how multimodal image-and-text models are built and trained, and why modern LLMs use layer normalization or RMSNorm with pre-norm placement instead of batch normalization.

    Machine LearningTechnical Screen
  • ByteDanceMediumMachine Learning Engineer
    Explain XGBoost's Overfitting Resistance

    This question evaluates understanding of ensemble learning and model generalization, focusing on why gradient-boosted tree ensembles are often less prone to overfitting than single decision trees.

    Machine LearningTechnical Screen
  • ByteDanceMediumSoftware Engineer
    Hand-Write a Multi-Head Attention Layer: Projections, Head Splitting and Masking

    Write a multi-head attention layer from scratch: project queries, keys and values, split them into heads, apply scaled dot-product attention with optional padding or causal masks, and merge the heads. It tests tensor shape discipline, numerical stability, and the cost of attention as sequence length grows.

    Machine LearningOnsite
  • ByteDanceHardData Scientist
    How to deploy and tune multimodal models?

    A six-part ByteDance data scientist onsite ML interview covering deploying and tuning multimodal models under GPU/VRAM, compute, and latency constraints; designing fast video retrieval over precomputed captions and embeddings with ANN and hybrid reranking; and deep-learning fundamentals — overfitting detection and mitigation, dropout and inverted-dropout scaling, normalization layers (BatchNorm/LayerNorm/GroupNorm/InstanceNorm/RMSNorm), and reinforcement learning for LLM post-training (RLHF). It tests practical systems tradeoffs alongside theoretical foundations across ML systems, retrieval, and reinforcement learning.

    Machine LearningOnsite
  • ByteDanceMediumData Scientist
    How would you choose a classification threshold?

    This question evaluates understanding of threshold selection for probabilistic binary classifiers, testing competencies in validation-set decision threshold choice, cost-sensitive trade-offs between false positives and false negatives, effects of class imbalance, and probability calibration.

    Machine LearningTechnical Screen
  • ByteDanceMediumApplied Scientist
    Implement Multi-Head Attention from Scratch

    An ML coding question asking you to implement multi-head attention from scratch in NumPy or PyTorch, from the query, key and value projections to the output projection. It tests tensor shape handling, scaled dot-product attention, masking, numerical stability and complexity analysis.

    Machine LearningTechnical Screen
  • ByteDanceHardMachine Learning Engineer
    Implement a Transformer Decoder from Scratch Without Starter Code

    Implement a transformer decoder from scratch with no starter code in about 30 minutes, including embeddings, masked multi-head self-attention, feed-forward layers, residual connections and layer normalization. Tests tensor-shape fluency, causal masking and hands-on deep learning coding for a machine learning engineer interview.

    Machine LearningTechnical Screen
  • ByteDanceHardData Scientist
    Predict Short-Video Engagement with Skewed Data

    Design a short-video engagement model with explicit targets, leakage-safe features, heavy-tail handling, exposure awareness, and temporal evaluation.

    Machine LearningTechnical Screen
  • ByteDanceMediumApplied Scientist
    Write the Cross-Entropy Loss and Compute Precision, Recall and F1

    An ML fundamentals question in two parts: write the cross-entropy loss for binary and multi-class classification and explain why it is used, then compute precision, recall, F1 and accuracy for a described imbalanced classifier. It tests exact formulas, careful arithmetic and metric choice.

    Machine LearningTechnical Screen
  • C3 AIMediumData Scientist
    Choose Tokenization and Dense or Sparse Retrieval

    This problem tests your understanding of document retrieval strategies, specifically comparing sparse and dense representations and how to integrate them into a production RAG system.

    Machine LearningTechnical ScreenRAGNLPInformation Retrieval
  • C3 AIMediumData Scientist
    Choose a Parameter to Reduce Underfitting in Gradient-Boosted Trees

    Explain why decreasing minimum observations per leaf can reduce gradient-boosted tree underfitting and how to validate the change.

    Machine LearningOnline Assessment
  • C3 AIMediumData Scientist
    Compare How Models Respond to Multicollinearity

    Compare multicollinearity effects in regression, Lasso, logistic regression, decision trees, and boosted trees without overstating immunity.

    Machine LearningOnline Assessment
  • C3 AIHardData Scientist
    Compare PCA and Autoencoders Under the Curse of Dimensionality

    This question tests your conceptual understanding of dimensionality reduction techniques and your ability to weigh their performance in high-dimensional feature spaces prone to the curse of dimensionality.

    Machine LearningTechnical ScreenDimensionality ReductionPCAAutoencoders
  • C3 AIHardData Scientist
    Compare Transformers and RNNs and Derive Attention Complexity

    Evaluate candidate's deep learning foundations by comparing Transformer and recurrent architectures and deriving exact time/memory complexities for standard scaled dot-product attention across training and inference.

    Machine LearningTechnical ScreenTransformersRNNAttention Mechanism
  • C3 AIHardData Scientist
    Connect Bias-Variance Trade-offs to Bagging and Boosting

    This question tests the conceptual understanding of how ensemble methods manipulate model error components through different structural paradigms.

    Machine LearningTechnical ScreenBias-VarianceEnsemble LearningBagging
  • C3 AIMediumSoftware Engineer
    Evaluate Factual Accuracy and Consistency in a Domain-Specific RAG Chatbot

    Evaluate a rare-disease RAG chatbot using domain consistency and expert review, and distinguish factual accuracy from retrieval metrics and lexical overlap.

    Machine LearningOnline Assessment
  • C3 AIMediumData Scientist
    Explain key ML/stats concepts

    Explain key ML/stats concepts evaluates core ML concepts, assumptions, math intuition, training/evaluation trade-offs, and practical failure modes in a realistic interview setting. A strong answer states assumptions, handles edge cases, explains trade-offs, and shows how to validate the result clearly.

    Machine LearningOnsite
  • C3 AIMediumData Scientist
    Explain the Margin View of Boosting Classification

    Understand boosting classification through sequential learners, signed margins, surrogate losses, and the limits of training-margin claims.

    Machine LearningOnline Assessment