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 list of IOUs (debtor, creditor, amount in cents) among a small group of people, return the minimum number of person-to-person transfers needed so that everyone's net balance is zero.
A customer's vendor master has duplicates created by different teams. Two vendors belong to the same real supplier if they share a normalized tax ID, bank account, or a corporate (non free-mail) email domain, and the relation is transitive. Return the duplicate groups.
Frontline workers such as store associates and nurses share devices, work shifts and rarely sit at a desk. How would you improve Outlook mobile for them?
Given the assets in a Roblox experience and dependency pairs (asset requires another asset to load first), return a load order that is lexicographically smallest among valid orders, or report the assets stuck in a dependency cycle.
A naive transpose of a large row-major matrix runs several times slower than a copy of the same size; explain why in terms of cache lines and TLB, then implement a tiled transpose and reason about the tile size.
Given daily prices of one asset and a fixed cost charged on every round trip, you may hold at most one unit at a time; return the maximum achievable profit.
A pooled ride has n riders, each with a pickup Pi and a drop-off Di. List every ordering of the 2n stops in which each rider's pickup comes before their drop-off, and give a formula for how many there are.
Build a structure over a folder tree that returns total bytes and file count under any folder, and stays correct as files are added, items are deleted, and folders are moved, while rejecting moves into a descendant.
An internal admin gateway for ByteDance tools must only accept requests from approved office and VPN ranges written in CIDR notation; implement the membership check and explain how a prefix like /22 maps to a bitmask.
Split each user's Reels view events into sessions that end after 30 minutes of inactivity or once a session would run longer than two hours from its start, and return session start, end and event count.
Given a routing table of IPv4 CIDR prefixes such as 10.1.0.0/16 mapped to next hops, implement lookup(ip) that returns the next hop of the most specific (longest) matching prefix, or None if nothing matches.
Given listing titles keyed by id and a query using words, AND, OR, NOT and parentheses (adjacent words mean AND), return the sorted ids of listings whose titles satisfy the query, and raise an error for malformed queries.
Design the service that issues refunds when a return is accepted, sending money back to the original card, gift card balance or split payment, at the right time and exactly once.
For a 70B parameter decoder-only transformer with 80 layers, hidden size 8192, and 64 attention heads of dimension 128, estimate the key-value cache memory per token and per 32k-token request in fp16, then show how grouped-query attention with 8 KV heads changes how many concurrent long requests fit on an 8-GPU node with 80 GB each.
An n by n grid starts fully blocked. Cells open one at a time in a given order. Return the 1-based step at which some path of open cells first connects the top row to the bottom row, or -1 if it never does.
Fraud affects 0.5% of card-not-present transactions. A device signal flags 90% of fraud and 5% of good transactions, and a merchant velocity rule flags 80% of fraud and 10% of good transactions. What is the probability of fraud when both fire, first assuming conditional independence and then when the rules are correlated among good transactions?
Tell me about a time you were pulled into a high-severity customer escalation caused by a defect in software you or your team owned, where data integrity or availability was at stake. What did you do, and what changed afterward?
Given a 4 by 4 board of tile values (0 for empty) and a swipe direction, slide all tiles that way, merging equal neighbors once per move as in 2048. Return the new board, the points gained (sum of merged tile values), and whether the board changed.
Facebook Dating wants to change how its match queue orders candidate profiles. Because both sides of a match share the same pool, explain why a user-split test is biased and design a city-level switchback test instead.
Given queue scan records (attraction, enter_time, exit_time) with exit times exclusive, return for each attraction the peak number of guests in line at once and the earliest time that peak was reached.
Get the full picture with our company interview guides.
Tell us what you were asked. Get 1 AI interview credit for each approved report.