practice a little every day — you've got this ♡
Interview Practice Problems
Practice 5974 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.
- 5974
- Problems
- 2212
- Auto-graded
- 15
- Topics
- 269
- Added today
Showing 181–210 of 5974 results
- Machine LearningMediumModel answerTenant-Safe Next-File Suggestions with Live Permission Checks
Design a low-latency recommender that proposes the next file a user will open while keeping each company's data isolated and respecting constantly changing file permissions.
Machine Learningrecommender-systemsmulti-tenancyaccess-controlcold-start - Trees & GraphsEasyModel answerCount Activations per Node in a Cascade Graph
Given a DAG of task dependencies and one start node, compute how many times each node fires when every activation fans out once along every outgoing edge.
Trees & Graphsdagtopological-sortpath-countinggraph-traversal - Arrays & HashingMediumAuto-gradedFirst-Week Post Totals and Week-Later Return Share
Group dated activity rows by user, find each user's earliest date, total posts in the first seven days, and compute the share of users active on day 7 or later.
Arrays & Hashinghash-mapdatesaggregationcohort-analysis - Heaps, Sorting & SearchMediumModel answerAssign Meetings to Rooms and Find the Most-Used One
Simulate meetings being placed into n numbered rooms, delaying them when all rooms are full, then report the room that hosted the most meetings, preferring the lowest index on ties.
Heaps, Sorting & Searchheapsimulationpriority-queueintervals - Trees & GraphsMediumAuto-gradedLandmass Tally: Count Regions and Find the Biggest
Count 4-connected groups of land cells in a binary grid and report the area of the largest group, testing graph traversal with correct visited-state handling.
Trees & Graphsgraphdfsbfsgrid - Data Structure DesignMediumAuto-gradedRLE Vector Dot Product and Execution Log Processor
Compress sparse sequences into run-length encodings, calculate their dot product, and analyze nested call timestamps using a call stack.
Data Structure Designarraysstackstwo-pointersdesign-ds - Heaps, Sorting & SearchMediumModel answerTop Words in a Huge Text File Under Tight Memory
Count word frequencies in a text file far larger than RAM, with explicit tokenization rules and an efficient exact top-K, and analyze time, memory and disk costs.
Heaps, Sorting & Searchword-countstreamingexternal-memorytop-k - Machine LearningEasyModel answerTrading Off Precision and Recall in Production Classifiers
Decide when a product classifier should favor precision or recall, and explain how to set its decision threshold using error costs, capacity limits, class imbalance, and post-launch monitoring.
Machine Learningprecision-recallthreshold-selectioncost-sensitive-learningclass-imbalance - System DesignMediumModel answerBuilding a Tenant-Isolated Vault for Confidential PDF Review
Design a backend for sharing sensitive PDFs across organizations with fast permission revocation, per-viewer watermarks, and a tamper-evident record of every access.
System Designsystem-designaccess-controlmulti-tenancyaudit-logging - Heaps, Sorting & SearchEasyAuto-gradedLocate the Span of a Value in a Sorted List
Use binary search to find the first and last positions of a value in a sorted list in logarithmic time, returning [-1, -1] when it is absent.
Heaps, Sorting & Searchbinary-searchsorted-arrayboundaries - Greedy & IntervalsMediumAuto-gradedCoalesce Overlapping Ranges Into Disjoint Spans
Combine unsorted inclusive integer ranges that share at least one point into disjoint spans ordered by start, testing endpoint handling, chained merges, and nesting.
Greedy & Intervalsintervalssortinggreedysweep - System DesignMediumModel answerSecure Storefront Backend: Accounts, Carts and Safe Checkout
Design a storefront backend where users sign up, log in, browse products, manage a personal cart and place orders safely, while APIs block access to other users' data.
System Designauthenticationauthorizationidempotencysession-management - BehavioralMediumModel answerDeep Dive: Leading a High-Stakes Technical Initiative
Learn how to structure and present a story about leading a complex engineering project, focusing on technical decision-making, stakeholder alignment, and self-reflection.
BehavioralLeadershipBehavioralSystem DesignStakeholder Management - Machine LearningMediumModel answerMitigating Overfitting and Analyzing Mean Squared Error Loss
A deep dive into diagnosing and fixing model overfitting alongside a statistical breakdown of Mean Squared Error loss and its alternative objectives.
Machine Learningoverfittingregularizationloss-functionsregression - SQL & DataMediumModel answerPoint-in-Time User Features and 30-Day Purchase Label in SQL
Build a leakage-free training table at a fixed snapshot: deduplicated, arrival-aware 7-day activity features per user, plus a forward-looking 30-day purchase label.
SQL & Datasqlfeature-engineeringpoint-in-timededuplication - StringsEasyAuto-gradedAccess Log Health Report with Strict Line Validation
Validate access-log lines field by field, then count client errors, server errors, invalid lines and the failure percentage over the valid lines only.
Stringsstringsparsingvalidationsimulation - Trees & GraphsMediumAuto-gradedShortest Word Chain Allowing One or Two Letter Swaps
Find a shortest word chain where each step swaps one or two letters, with a fixed tie-break, using BFS on an implicit graph and wildcard bucketing for fast neighbor lookup.
Trees & Graphsbfsshortest-pathstringshashing - BehavioralHardModel answerSteering a Vague Project, Then Triaging a Sudden DAU Drop
A two-part behavioral and analytical prompt: tell a story about bringing clarity to a vague, PM-led effort, then lay out a 48-hour response to a 20% DAU drop after a UI release.
Behavioralbehavioralleadershipincident-responsemetrics - BehavioralMediumModel answerCareer Overview and Navigating Unclear Requirements
Give a concise, metric-driven tour of your career as an ML engineer, then tell a structured story about working through ambiguity and describe the habits you rely on.
Behavioralbehavioralambiguityresume-walkthroughstar - Data Structure DesignMediumAuto-gradedImplement a Timed Workspace Credit System
Process a sequence of timestamped operations managing workspace balances, immediate transfers, scheduled/cancelled future transfers, and ranked queries.
Data Structure Designheaps-sortingdesign-dsarrays - Data Structure DesignMediumAuto-gradedSpaced Points Stream: Cancel a Nearby Point or Insert
Maintain a dynamic ordered set of numbers and, per arrival, find the smallest stored value in a closed window around it, deleting it or inserting the newcomer.
Data Structure Designordered-setbalanced-bstbinary-searchstreaming - Data Structure DesignMediumAuto-gradedTrade Join With Expiring Partial Records
Simulate a stream join that pairs order and price events by ID, using a min-heap with lazy deletion to expire unmatched partial records.
Data Structure Designhash-mapheapsimulationstream-processing - Statistics & ExperimentsEasyModel answerExplaining Underfitting vs Overfitting to a Business Audience
Describe, in plain language for non-technical colleagues, why a prediction model must balance being too simple against being too tailored to past data, and how to judge it.
Statistics & Experimentsbias-varianceoverfittingunderfittingcommunication - Math & Bit ManipulationMediumAuto-gradedCheapest Acorn Delivery Route for a Chipmunk on a Grid
Compute the minimum total steps to ferry every item to a single target cell on an open grid, carrying one at a time, using Manhattan distances and a smart choice of the first pickup.
Math & Bit Manipulationgreedymanhattan-distancegridmath - Heaps, Sorting & SearchMediumAuto-gradedCombine Several Ascending Sequences into One Sorted Sequence
Merge k individually sorted integer arrays into a single sorted array, testing heap-based k-way merging or pairwise divide-and-conquer and the associated complexity analysis.
Heaps, Sorting & Searchheapk-way-mergedivide-and-conquersorting - SQL & DataMediumAuto-gradedDaily Active Users, New-User Cohorts and Next-Day Return Rate
Build a fixed 7-day report of active users, first-activity cohorts, next-day return rate and revenue per active user from raw logs, with bot filtering and deduplication.
SQL & Datacohort-analysisretentiondeduplicationhash-sets - Math & Bit ManipulationMediumModel answerRunners Dodging Bouncing Sentries Along a Track
Count how many runners, released one per time unit, cross a track without ever sharing a cell at the same integer time with a sentry that bounces back and forth inside a fixed range.
Math & Bit Manipulationsimulationmodular-arithmeticperiodic-motionparity - BehavioralMediumModel answerResolving a Deep Disagreement With a Close Collaborator
Tell a story about a substantive technical or strategic clash with a trusted colleague, covering how you understood their view, how the decision was made, and how the relationship held up.
Behavioralbehavioralconflict-resolutiondisagree-and-commitcollaboration - BehavioralMediumModel answerBackend Leadership Interview: Reliable Systems, Reversals, and Pushback
A four-part behavioral practice round for senior backend engineers covering a flagship project with idempotency and SLA depth, a reversed decision, a challenged design, and motivation.
Behavioralbehavioralidempotencyslasenior-backend - System DesignMediumModel answerDesigning a Safe Card-Charging Flow with Retries and Storage
Design a backend flow for charging customers through an external payment provider so no one is billed twice and no payment is lost, then pick what to persist and which database to use.
System Designidempotencypaymentsretriesdatabase-design