← Uber Interview Insights

Uber·Machine Learning Engineer·Technical Phone Screen·Senior

SeniorPrefer not to say
Apr 2026

Summary

Uber MLE interview with a single coding question that was more math-flavored than I expected. No LeetCode number, just a black-box optimization problem. Felt pretty clean once I landed on the right approach, though I almost overthought the termination condition.

Questions Asked (1)

Q1

You're given a black-box convex function F(x) that you can only evaluate by querying it at specific x values. Given a search interval [a, b], find the x that minimizes F(x). You cannot compute gradients, only query function values.

Algorithms & Data StructuresTechnical Trade-offs
Author's notes

Ternary search clicked for me pretty fast since the function is unimodal.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by clarifying the problem constraints (e.g., convexity, query budget, precision) and then propose a derivative-free optimization method like ternary search or golden-section search. Explain the algorithm step-by-step, analyze its time complexity, and discuss practical considerations such as noise and parallelization.

Pro tip: Mention that golden-section search is more query-efficient than ternary search because it reuses one function evaluation per iteration, which matters when queries are expensive. Also, note that if the function is noisy, you may need to use stochastic approximation or increase evaluations per point.

1. Clarify assumptions and constraints

Ask about convexity (strict vs. non-strict), query cost, noise, and desired precision. Confirm whether the interval is finite and if the minimum is guaranteed to be inside.

2. Choose a derivative-free optimization algorithm

Select an algorithm like ternary search or golden-section search that uses only function evaluations. Explain why it works for convex functions.

3. Describe the algorithm steps

Outline the iterative procedure: evaluate at two interior points, compare values, and discard the subinterval that cannot contain the minimum. Repeat until the interval is sufficiently small.

4. Analyze complexity and convergence

State the number of iterations needed for a given precision (logarithmic in 1/epsilon) and the number of function evaluations per iteration. Compare ternary vs. golden-section in terms of query efficiency.

5. Discuss practical considerations and extensions

Address noise handling, parallel evaluation, and alternative methods like Bayesian optimization if queries are very expensive. Mention trade-offs between simplicity and query efficiency.

Key Points to Mention

  • Convexity guarantees a unique minimum (if strict) and allows interval reduction methods.
  • Ternary search: two evaluations per iteration, reduces interval by 2/3 each time.
  • Golden-section search: one new evaluation per iteration, reduces interval by ~0.618 each time, more query-efficient.
  • Time complexity: O(log(1/epsilon)) iterations, each with O(1) evaluations.
  • Handling noisy evaluations: use repeated queries or stochastic methods.
  • Parallelization: evaluate multiple points simultaneously to speed up search.

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