practice a little every day — you've got this ♡
Interview Practice Problems
Practice 5987 original coding, SQL, system design, machine learning and behavioral problems across 15 topics. Coding and SQL problems run against hidden test cases right in your browser; every problem has hints and a worked solution, free.
- 5987
- Problems
- 2219
- Auto-graded
- 15
- Topics
- 270
- Added today
Showing 361–390 of 5987 results
- Stacks & QueuesEasyAuto-gradedLeftover Brackets After Pairing Up a Parenthesis String
Count the parentheses left over after forming the maximum number of valid "(" before ")" pairs, testing a greedy counter scan or stack over a string.
Stacks & Queuesstackgreedystringsparentheses - BehavioralMediumModel answerFive Behavioral Stories Every ML Engineer Should Have Ready
Build structured, quantified stories for pride, difficult colleagues, tight deadlines, shifting scope and mentoring, each ending with a lesson and a concrete change in behavior.
Behavioralbehavioralstar-methodleadershipcommunication - System DesignMediumModel answerExactly-Once Disbursements Across Flaky Banking Rails
Design a payout service that never moves money twice despite client retries, parallel workers, and gateway timeouts during peak payroll bursts.
System Designidempotencypaymentsdistributed-systemsstate-machine - System DesignEasyModel answerSubtracting Two Sensor Feeds with Late-Arriving Corrections
Design the contract for subtracting two timestamped numeric streams, including missing and duplicate timestamps, and a versioned, idempotent way to publish corrections for late events.
System Designstreamingidempotencyevent-timedata-contracts - System DesignMediumModel answerProfiling CPU, Cache, and Disk Stalls in a Low-Latency Engine
Build a measurement-first diagnosis and fix plan for three latency problems in a C++ trading service: CPU saturation, cache-hostile memory use, and slow synchronous log writes.
System Designperformanceprofilinglow-latencylinux - Trees & GraphsMediumAuto-gradedReach the Goal State While Avoiding Forbidden Nodes
Decide whether a goal node can be reached from node 0 in a directed graph without ever stepping on a forbidden node, using BFS or DFS reachability.
Trees & Graphsgraphbfsreachabilitydirected-graph - Trees & GraphsMediumAuto-gradedFirst Moment a Cable Network Becomes One Piece
Replay unsorted timed link events and find the earliest timestamp at which every node is in one connected group, using union-find over events sorted by time.
Trees & Graphsunion-findgraph-connectivitysortingkruskal - Data Structure DesignMediumAuto-gradedSimulate Stacked Rectangles on a Small Text Canvas
Simulate add, remove, reorder and render commands on a layered character canvas, resolving overlaps by layer order and clipping shapes at the edges.
Data Structure Designsimulationordered-dictdesignclipping - Greedy & IntervalsMediumAuto-gradedMost Overlapped Aisle Along a Line of Lamps
Find the integer position covered by the most symmetric intervals, returning the smallest on ties, using an event sweep over interval endpoints instead of visiting every position.
Greedy & Intervalssweep-lineintervalsdifference-arraysorting - Arrays & HashingMediumAuto-gradedZigzag Parity Check on Subarray Ranges
Answer many range queries asking whether neighbors in a subarray always differ in odd/even parity, using prefix counts of same-parity adjacent pairs.
Arrays & Hashingprefix-sumrange-queriesparityarrays - Machine LearningHardModel answerDesigning an ML-Driven Workload Allocator for Delivery Drivers
Design a system that forecasts stop service times with ML and feeds them to a constrained optimizer to split a shift's deliveries across drivers, balancing punctuality and fairness.
Machine Learningoptimizationgradient-boostingcold-startdistribution-shift - Greedy & IntervalsMediumAuto-gradedMax Speed Continuous Window on Ticked Rate Stream
Find the maximum average throughput over a continuous time window of a specified size, given rate logs over uniform time ticks.
Greedy & Intervalssliding-windowtwo-pointersgreedyprefix-sum - System DesignMediumModel answerBuilding an Automated Playbook Miner for Enterprise AI Agents
Design an end-to-end system that mines reusable agent playbooks from a company's traces and documents, tests them offline, ships them safely to agents, and keeps them current.
System Designllm-systemsagentsml-system-designevaluation - System DesignHardModel answerCost Model for a Two-Matmul MLP Block Across Devices
Derive FLOPs, bytes moved, and collective traffic for a plain two-matmul MLP under several partitioning schemes, then decide which hardware limit binds.
System Designml-systemstensor-parallelismrooflinecollectives - Arrays & HashingEasyAuto-gradedWord-Count Cosine Score for Two Text Strings
Compute the cosine of the angle between the word-frequency vectors of two strings, using a hash-map counter and guarding against empty inputs.
Arrays & Hashinghash-mapcountingstringsmath - Statistics & ExperimentsHardModel answerDesign an Ad Density Experiment with Safety Boundaries
Design a robust A/B test for introducing additional feed ads, balancing immediate revenue gains against long-term user retention, marketplace side effects, and experimental biases.
Statistics & ExperimentsAB TestingExperimental DesignCausal InferenceMetrics Strategy - Arrays & HashingMediumAuto-gradedCount Squares Spanned by Crossing Vertical and Horizontal Segments
Count axis-aligned squares whose four corners all lie where a vertical segment meets a horizontal one, using per-row bitmasks and pairwise row comparison.
Arrays & Hashinggeometrybitmaskhashingenumeration - Data Structure DesignMediumAuto-gradedLog Record Dedup: Batch Merge and Watermarked Replay
Deduplicate log records by event id under a first or latest policy, then replay an operation list through a watermark-based stream deduplicator that drops late data and evicts finalized entries.
Data Structure Designhash-mapsortingstreamingwatermark - Trees & GraphsMediumAuto-gradedIndented Staff Listing from Direct-Report Pairs
Build a forest from (employee, manager) pairs and output each person with their depth in a sorted depth-first order, handling very deep chains iteratively.
Trees & Graphstreedfsforesthash-map - BehavioralMediumModel answerFour Behavioral Stories: Impact, Uncertainty, Feedback, Friction
Prepare structured stories showing ownership and measurable impact, handling vague goals, acting on feedback, and managing a tense relationship with a manager or stakeholder.
Behavioralbehavioralleadershipstar-methodambiguity - BehavioralEasyModel answerAnswering Internship Length, Start Date and Return-Offer Questions
Practice giving a precise, honest answer about internship length, start window, full-time conversion and constraints such as classes, visa status and location.
Behavioralbehavioralinternshipavailabilitycommunication - System DesignMediumModel answerBlocking Government-Listed IPs at the Edge of a Global Service
Design a fleet-wide system that rejects connections from IP addresses a regulator flags as prohibited, using only the regulator's per-address lookup API as the source of truth.
System Designsystem-designnetworkingcachingtrie - Data Structure DesignMediumModel answerBuild a Fire-Once Event Gate for Concurrent Threads
Design a thread-safe one-shot event gate with fire, timed wait and non-blocking status check, avoiding lost wakeups, spurious-wakeup bugs and busy-waiting.
Data Structure Designconcurrencycondition-variablethreadingsynchronization - Machine LearningMediumModel answerTwo ML Cases: Predicting Flight Lateness and Screening Faces Against a Watchlist
Design two ML systems end to end: a regression model forecasting flight departure lateness two hours out, and an open-set face-matching pipeline that flags watchlist individuals at a bank entrance.
Machine Learningregressionlabel-leakagetime-series-validationimbalanced-classification - BehavioralMediumModel answerNavigating Noisy Data and Uncertainty in Quantitative Research
Articulate your intellectual drive for quantitative research by framing a past data problem, detailing your statistical approach to ambiguity, and connecting it to financial modeling.
Behavioralquant researchbehavioralstatisticsdata modeling - System DesignMediumModel answerTopic-Based Article Aggregator: Crawling, Dedup, and Feed Serving
Design a service that polls tens of thousands of external publishers, stores articles without duplicates, and serves topic timelines with stable pagination under 50ms p99.
System Designsystem-designschedulingdeduplicationcaching - System DesignMediumModel answerBuild a Multi-Tenant Time-Series Telemetry Backend
Design a horizontally scalable telemetry backend that ingests millions of labeled data points per second, stores 30 days of history, and serves fast label-filtered range queries.
System Designsystem-designtime-seriesobservabilityingestion-pipeline - BehavioralEasyModel answerTell Your Story: Career Summary and Reasons for a Move
Give a concise professional introduction, explain honestly why you are open to a new job, and describe which factors matter most when choosing an employer.
Behavioralbehavioralrecruiter-screenself-introductionmotivation - Data Structure DesignMediumModel answerWeighted Random Picker with Live Weight Updates
Build a container that returns items at random with probability proportional to their weights, supports re-weighting existing items, and keeps picks fast and memory small.
Data Structure Designfenwick-treeprefix-sumsrandom-samplingbinary-search - System DesignHardModel answerLive Courier Fleet Tracking and ETA Platform Design
Design an end-to-end platform that streams courier GPS, computes routes and ETAs, manages order assignment, and powers live maps for dispatchers and customers.
System Designsystem-designstreamingkafkageospatial