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
Write a small parser and evaluator for filter expressions such as `amount > 100 and (status == "ok" or country != "US")`, supporting comparisons, and, or, not and parentheses with correct precedence, then use it to compute count, sum or mean of a column over the rows that match.
Facebook Watch emits a heartbeat ping every 30 seconds while a video plays. Given (user_id, device, ts) pings, split them into sessions whenever two pings are more than two minutes apart and return the average session length per device.
Builds are numbered 1 to n, and once a build fails its health checks every later build fails too. Given an is_bad(build) API that is expensive to call, find the first failing build with as few calls as possible.
As an engineering manager, describe a program you delivered that needed several teams (for example app, payments, logistics and seller platform) to ship together. How did you plan it, keep it on track, and handle slips?
A Borg-style job queue is a singly linked list of priority scores. Rearrange it so every job with score below a threshold x comes before every job with score at least x, preserving the original relative order inside each group.
A Google Sheets formula string contains only round brackets. Return the minimum number of '(' or ')' characters you must insert anywhere so the brackets are balanced.
Explain the BERT masked language modeling objective and T5's span corruption objective, compute how much each costs per training example, and discuss what each teaches the model.
A road network has edges each with a maximum truck weight; for each query (p, q, w), decide whether a truck of weight w can travel from p to q using only roads whose limit exceeds w. Answer all queries efficiently.
Implement a limiter that allows at most N calls per sliding window of W seconds for each (tenant, connector) pair, such as Acme's calls into ServiceNow, and reports how long a rejected caller should wait before retrying.
Slack's free plan once capped history at the most recent 10,000 messages. As the PM, evaluate switching to a rule that shows only the last 90 days of messages and files, and say how you would decide and measure it.
Implement a thread-safe rate limiter that allows each user a burst of up to C requests and refills at R requests per second, so lightning deal endpoints can reject scripted clients without blocking normal shoppers.
Pins of varying heights arrive in ranked order and must be placed into a fixed number of equal-width columns, each Pin going to the currently shortest column (leftmost on ties). Return the column for each Pin and the final column heights.
Users spend coins to send LIVE gifts, and a client may retry the same request after a timeout while another device spends from the same balance. Using a relational database, implement spend(user, amount, idempotency_key) so the balance never goes negative and a retried request is applied exactly once.
A new default daily screen time reminder for teen users reduces their watch time by 4% in an experiment. How would you evaluate whether it is a success and present it to leadership?
n players each start in a solo party; process a list of accepted invites (a, b) in order, merging their two parties unless the merged size would exceed a cap, and report for each invite whether it merged, was rejected, or the players were already together.
Build a small in-memory MVCC key-value store: each transaction reads a consistent snapshot, sees its own writes, and commits with first-committer-wins conflict detection. Include garbage collection of versions no snapshot can see.
A technician starts at the top-left of a data hall grid with open floor (0), fire (1), and walls (2), and must reach the exit at the bottom-right. Each minute the technician moves one cell, then fire spreads to adjacent open cells; return the maximum minutes they can wait before leaving and still escape, -1 if impossible, or 10^9 if any wait works.
Design the service that fires Google Calendar reminders (push, email, in-app) at the right moment for hundreds of millions of users, including recurring events and edits made minutes before the reminder is due.
Given a list of product codes in the order they were scanned, return the first code that appears exactly once, or None if every code repeats. Then extend it to support codes arriving one at a time with a query for the current first unique code.
Tell me about a time you were confident in a decision, actively sought out people who might disagree, and ended up changing your mind. How did you find those perspectives?
Get the full picture with our company interview guides.
Tell us what you were asked. Get 1 AI interview credit for each approved report.