Practice questions for 300+ companies, plus questions candidates reported from their interviews.
11,568 questions · 341 companies · 1,114 reported by candidates
Showing 11,568 results
Given a stream of per-order slippage values in basis points, output the median of every window of the last k values, using O(log k) work per new value.
Design the ranking system that orders accounts and hashtags when a user types a query into Instagram search. Consider prefix matching, social relevance, popularity and abuse such as impersonation accounts.
Roads between intersections are undirected with travel times, and some are toll roads. A rider's preference allows at most K toll roads. Return the minimum travel time from source to destination respecting that limit, or -1 if unreachable.
Orders arrive as (price, amount, type). A buy matches the cheapest resting sell with price <= its price; a sell matches the highest resting buy with price >= its price. Unmatched quantity rests in the backlog. Return the total resting amount at the end.
Tell me about a time you had a long backlog of customer-requested features and limited engineering capacity. How did you decide what to build first?
For users who published their first Instagram Reel, compute the share who published another Reel within 14 days, broken down by how many views the first Reel got in its first 24 hours (0 to 9, 10 to 99, 100 to 999, 1000 or more).
The Facebook growth team sends a reminder notification to users predicted most likely to return. A colleague argues they should instead target users whose return probability increases most because of the notification. Explain the difference and how you would build and evaluate an uplift approach.
Amazon Fresh charges Prime members a delivery fee on orders below a basket threshold. A leader proposes removing the fee to grow weekly usage. Analyze the decision and recommend what to do.
Describe a time a security or privacy reviewer required changes to your design that you felt were excessive. How did you resolve it?
Design how API and ChatGPT Enterprise requests from customers who choose a data residency region (for example Europe) are processed and stored only in that region, while the rest of the platform stays global.
Describe a decision where improving a product metric would have required collecting or using more user data than you were comfortable with, and what you did instead.
Given a login events table for a newly launched mobile game, write SQL that reports daily active users per day and, for each install cohort day, the share of new players who came back the next calendar day.
Build an autocomplete structure for Rakuten Ichiba search that records queries with counts and returns the three most frequent queries starting with a given prefix, breaking ties alphabetically, while counts keep increasing.
Concatenating two video segment files costs the sum of their sizes, and the result becomes a new segment. Return the minimum total cost to combine all segments into one file.
A search query builder receives expressions with unbalanced parentheses and other characters. Remove the minimum number of parentheses so the result is balanced, and return every distinct result achievable with that minimum.
Write serialize and deserialize functions for a binary tree of category names so the tree can be cached as one string and rebuilt exactly. Names may contain any characters, including commas, colons and the null marker.
A city map is a binary grid where 1 marks a block inside a delivery zone, and connected 1s (four-directionally) form one zone. Return how many distinct zone shapes exist, where two zones have the same shape if one can be translated onto the other without rotation or reflection.
Design the client-side image cache for the Instagram mobile app, including memory and disk tiers, prefetching images just ahead of the scroll position in feed, and eviction under tight storage limits.
Before a storage service writes an index snapshot, it must confirm the binary tree is height balanced: at every node the heights of the two subtrees differ by at most one. Return whether the tree passes.
A portfolio manager candidate shows 400 independent trades with a 55 percent hit rate. Test whether this is evidence of skill versus a coin flip, and explain what else you would need before concluding anything.
Get the full picture with our company interview guides.
Tell us what you were asked. Get 1 AI interview credit for each approved report.