← Amazon Interview Insights

Amazon·Machine Learning Engineer·Technical Phone Screen·Intermediate

Intermediate
May 2026

Summary

Amazon ML engineer screen, one technical question on regression fundamentals. Pretty short and focused, felt more like a warmup than a deep dive.

Questions Asked (1)

Q1

What are the key differences between linear and logistic regression?

Technical Trade-offs
Author's notes

Knew this cold but still fumbled the output layer explanation a bit.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by defining both models and their core purpose: linear regression predicts continuous values, while logistic regression predicts probabilities for classification. Then contrast them across key dimensions such as output type, underlying function, loss function, and evaluation metrics. Finally, tie the differences to practical implications for model selection and trade-offs in real-world ML systems.

Pro tip: Emphasize that logistic regression is a linear model for classification, not regression, and highlight how the choice impacts interpretability, assumptions, and deployment. Mention that at Amazon, understanding these trade-offs is crucial for scalable, cost-effective solutions.

1. Define the problem type

Clarify that linear regression is used for regression tasks (predicting continuous outcomes), while logistic regression is used for binary classification tasks (predicting probabilities).

2. Explain the mathematical formulation

Describe how linear regression models the output as a linear combination of inputs, whereas logistic regression applies a sigmoid function to a linear combination to output probabilities between 0 and 1.

3. Compare loss functions and optimization

Contrast mean squared error (MSE) for linear regression with cross-entropy (log loss) for logistic regression, and note that both can be optimized via gradient descent but logistic regression uses maximum likelihood estimation.

4. Discuss evaluation metrics and assumptions

Mention that linear regression is evaluated with R-squared, MSE, etc., while logistic regression uses accuracy, precision, recall, AUC-ROC. Also note assumptions: linearity, independence, homoscedasticity for linear; linearity between log-odds and features for logistic.

5. Highlight practical implications

Explain how these differences affect model selection, interpretability, and deployment, such as logistic regression providing probabilities and being robust for classification, while linear regression is unsuitable for binary outcomes.

Key Points to Mention

  • Output type: continuous vs. probability (binary)
  • Link function: identity vs. sigmoid (logistic)
  • Loss function: MSE vs. cross-entropy
  • Evaluation metrics: R-squared/MSE vs. accuracy/AUC
  • Assumptions: linearity, independence, homoscedasticity vs. linearity of log-odds
  • Interpretability: coefficients represent change in output vs. change in log-odds

AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.