practice a little every day — you've got this ♡
Interview Practice Problems
Practice 6037 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.
- 6037
- Problems
- 2236
- Auto-graded
- 15
- Topics
- 273
- Added today
Showing 1171–1200 of 6037 results
- Machine LearningHardModel answerDesigning a Feed Ad Recommendation and Ranking Engine
Architect an end-to-end Machine Learning ad recommendation system for a content feed, balancing ad revenue with user experience, delayed feedback, counterfactual evaluation, and budget pacing.
Machine Learningrecommender-systemsrankingctr-predictionmulti-task-learning - Heaps, Sorting & SearchEasyAuto-gradedStream Median Tracker
Process a series of dynamic data stream queries to compute the median on demand using heap-based structures.
Heaps, Sorting & Searchheapsheapqdata-structuresdesign-ds - Data Structure DesignMediumAuto-gradedMost Connected User Tracker with Variable Top-K Queries
Maintain distinct-contact counts for users from undirected messages, answer the top user in O(1), and return a top-k list with deterministic tie-breaking.
Data Structure Designhash-sethash-mapheapsimulation - Stacks & QueuesMediumAuto-gradedStrip Unmatched Brackets From a Text Line
Delete exactly the brackets that cannot be paired so the remaining text is well-formed, using a single linear scan with a stack or counters.
Stacks & Queuesstackstringparenthesesgreedy - System DesignMediumModel answerElimination Quiz Arena: Scalable Live Game Backend Design
Design a backend for elimination-style live quiz games with many players per room, fair timing, crash recovery mid-round, and spectator traffic kept away from gameplay.
System Designsystem-designreal-timewebsocketssharding - Dynamic ProgrammingMediumAuto-gradedCalculate Processed Work Units in Pipelined Task Queues
Simulate task batch execution across a sequential multi-stage pipeline and count total units completed within a time limit.
Dynamic Programmingarrayssimulationdynamic-programminggreedy-intervals - System DesignHardModel answerDesign a Real-Time Multiplayer Matchmaking Service
Design a scalable, low-latency matchmaking architecture capable of handling millions of players across diverse modes while keeping matches balanced, fast, and crash-resilient.
System Designsystem-designdistributed-systemsgaminglow-latency - Machine LearningHardModel answerRater Reliability Metrics and Validating an LLM Grader
Explain how to quantify labeler reliability beyond raw agreement, when each metric fails, and how to decide whether an LLM can stand in for human graders.
Machine Learninginter-annotator-agreementcohens-kappakrippendorff-alphallm-as-judge - Dynamic ProgrammingMediumAuto-gradedBest Haul from a Line of Stalls Without Neighbors
Compute the maximum total from a line of non-negative numbers when no two neighboring entries may both be picked, using linear-time dynamic programming.
Dynamic Programmingdynamic-programmingarraytake-or-skiphouse-robber - BehavioralHardModel answerDeciding Whether to Pause or Ship a Powerful but Poorly Understood AI System
Discuss how to decide between further research, limited testing, and broad release of a powerful AI system with unknown risks, and how rivals who may not wait change that reasoning.
Behavioralai-safetydecision-makingethicsleadership - Machine LearningMediumModel answerWalking Through a Vision-Language Model Build, Start to Finish
Present a vision-language model you built, covering scope, architecture, data, training, modularity, serving latency, and failure modes, with consistent numbers and clear trade-offs.
Machine Learningvision-language-modelsmultimodalllm-traininginference-latency - System DesignMediumModel answerBackend Fundamentals: GIL, PUT vs PATCH, Cyclic GC, Lock Ordering
Answer four backend fundamentals for a payments service: Python concurrency and the GIL, PUT/PATCH with optimistic locking, CPython garbage collection, and deadlock avoidance.
System Designpythongilhttpoptimistic-concurrency - StringsMediumAuto-gradedExpand a Compact Letter-and-Count String
Parse a string of letters with optional multi-digit repeat counts, treating a missing count as one, and rebuild the expanded text in a single left-to-right pass.
Stringsstring-parsingtwo-pointerssimulationrun-length-encoding - System DesignHardModel answerBuild a Pausable GPU Workspace Platform for Research Teams
Design a service that hands out isolated, GPU-backed Jupyter-style workspaces that can be started, paused, and resumed on any host without losing files or packages, while controlling idle GPU spend.
System Designsystem-designgpu-schedulingpersistent-storagelifecycle-management - Machine LearningMediumModel answerImplement a Decoder-Only Autoregressive Transformer
Write PyTorch components for a decoder-only GPT model, specifying tensor shapes and handling causal masking, multi-head attention, and block architecture.
Machine Learningtransformersdeep-learningpytorchnlp - Statistics & ExperimentsHardModel answerGeometric Sessions, A/B Sizing, and Bootstrap on Skewed Engagement
Four linked statistics questions: geometric session probabilities, two-proportion sample sizing, why a t-test and bootstrap CI disagree on skewed data, and a ship/no-ship recommendation.
Statistics & Experimentsgeometric-distributionsample-sizeab-testingbootstrap - Statistics & ExperimentsMediumModel answerTwo-Arm Booking Uplift: Significance, Day Clustering, and Sizing
Analyze a one-week A/B test on booking conversion: run an unpooled z-test, apply an ICC design-effect correction, size a follow-up test, and plan heterogeneity checks.
Statistics & Experimentsab-testingtwo-proportion-z-testdesign-effecticc - Trees & GraphsMediumAuto-gradedBest Multi-Hop Exchange Rate Between Two Currencies
Find the largest product of directed exchange rates along any path between two currencies, using Bellman-Ford-style relaxation on a graph that may contain cycles and rates above 1.
Trees & Graphsgraphbellman-fordshortest-pathcurrency - BehavioralMediumModel answerOwning a Decision Built on Faulty Metrics
Prepare a behavioral answer about acting on flawed or misleading data: how you found the problem, what it cost, how you recovered, and which lasting safeguards you put in place.
Behavioralbehavioralownershipdata-qualityleadership - Data Structure DesignHardModel answerHardening a Coalescing TTL Cache: Failures, Invalidation, Eviction
Review a promise-coalescing TTL cache in TypeScript, find its failure, invalidation and memory bugs, write a fixed version, and explain how to port it safely to multithreaded C++20.
Data Structure Designasynccacherace-conditionslru - System DesignHardModel answerBuilding an Asynchronous Job Platform for LLM Requests
Design an asynchronous backend that accepts LLM requests, queues and routes them fairly, runs them reliably, and returns results, with cost, security and SLA controls.
System Designsystem-designllm-servingjob-queueidempotency - Trees & GraphsEasyAuto-gradedGrid Zone Coloring Feasibility
Determine whether empty grid plots can be assigned one of k colors without adjacent conflicts.
Trees & Graphstrees-graphsarraysmath-bits - System DesignMediumModel answerBuild a Real-Time Multi-User Document Editing Platform
Design a platform where many people edit one document simultaneously, covering merge rules, live streaming, durable history, reconnect, and periodic Git checkpoints.
System Designsystem-designcollaborationcrdtoperational-transform - Machine LearningEasyModel answerML Fundamentals: Generalization, Contrastive Embeddings, Attention
Explain how to diagnose and curb overfitting, how contrastive pretraining and its loss shape embeddings, and how a transformer block works.
Machine Learningoverfittingcontrastive-learninginfoncetransformers - System DesignHardModel answerBuild a Delayed-Task Platform with a Fast Status Cache
Design a distributed platform that runs delayed and immediate background tasks with retries and durable state, plus a cache that serves task status in under 10 ms at 10k requests/second.
System Designsystem-designjob-queuecachingidempotency - Stacks & QueuesEasyAuto-gradedRight-Side Larger Neighbor Lookup for Selected Values
Tests whether you can precompute the nearest strictly larger value to the right for every element using a monotonic stack, then answer lookups for a chosen list of values.
Stacks & Queuesmonotonic-stackhash-maparrays - Trees & GraphsMediumAuto-gradedGrid Contagion Simulation
Simulate multi-source BFS propagation across a 2D grid up to a maximum number of steps.
Trees & Graphsbreadth-first-searchmatrixgraph-traversal - Trees & GraphsMediumModel answerTwo Warm-Ups: One-Deletion Palindrome and Column-Grouped Tree Output
Decide whether a string becomes a palindrome after removing at most one character, then group a binary tree's node values by column using level-order tie-breaking.
Trees & Graphstwo-pointerspalindromebfsbinary-tree - Trees & GraphsMediumAuto-gradedEarliest Finish Time for a Dependent Job Pipeline
Compute the shortest total time to finish all jobs with unlimited parallelism by finding the longest weighted path in a dependency graph, returning -1 if a cycle exists.
Trees & Graphstopological-sortdaglongest-pathdynamic-programming - Data Structure DesignEasyAuto-gradedIn-Memory Store with Transaction Layering
Implement an in-memory key-value database supporting GET, SET, DELETE, and nested transaction semantics (BEGIN, ROLLBACK, COMMIT).
Data Structure Designdesign-dsstacks-queuesarraysstrings