practice a little every day — you've got this ♡
Data Structure Design Interview Problems
Practice 5969 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.
- 5969
- Problems
- 2211
- Auto-graded
- 15
- Topics
- 272
- Added today
Showing 1–30 of 375 results
- Data Structure DesignMediumAuto-gradedLocate a Traveler's Airport by Timestamp
Process a batch of operations that load travel records and answer per-user point-in-time location queries using grouping, sorting and binary search.
Data Structure Designbinary-searchhash-mapintervalsdesign - Data Structure DesignMediumAuto-gradedRoom Assignment and Leaderboard for Streaming Sessions
Simulate a stream of operations that assigns sessions to the lowest-numbered free room and reports the top-k streams by total duration, tested with heaps and lazy deletion.
Data Structure Designheapdesignsimulationlazy-deletion - Data Structure DesignEasyAuto-gradedSliding Five-Minute Hit Tally for Each Caller
Process a batch of hit and query operations, returning each caller's number of hits within an inclusive 300-second window, using per-caller queues with lazy expiry.
Data Structure Designhash-mapqueuesliding-windowsimulation - Data Structure DesignHardAuto-gradedBest-Fit Block Manager with Splitting and Merging
Simulate a best-fit memory manager on a fixed address range, handling splits, exact-start frees, invalid frees, and merging of neighboring free blocks using plain lists.
Data Structure Designsimulationbinary-searchmemory-allocatorbest-fit - Data Structure DesignMediumAuto-gradedSmallest Free Label per Category: Batch Simulation
Simulate a sequence of allocate and release operations on independent categories, always handing out the smallest free positive integer, using a counter plus a min-heap per category.
Data Structure Designheaphash-mapsimulationdesign - Data Structure DesignMediumAuto-gradedDesign an In-Memory Key-Value Engine with Transactions
Implement an in-memory key-value database supporting frequency counting and nested transaction rollbacks.
Data Structure Designhash-tablestackdesigndata-structures - Data Structure DesignEasyAuto-gradedSimulate a Time-To-Live (TTL) Key-Value Store
Process a series of operations on an in-memory key-value store with fixed time-to-live expiration dynamics.
Data Structure Designdesign-dshash-table - Data Structure DesignEasyAuto-gradedSimulate Driver Availability and Task Allocation
Simulate driver registration and dispatch operations using standard queue processing and state tracking.
Data Structure Designdata-structuresqueueshash-tablesimulation - Data Structure DesignMediumAuto-gradedCompute Compressed Vector Inner Product
Process dynamic creation of compressed vectors and compute inner products using sparse representations.
Data Structure Designarraysdesign-dshash-table - Data Structure DesignMediumAuto-gradedDesign a Recency-Tracking Key-Value Store
Simulate operations on a custom key-value map that efficiently queries the most recently updated active entry.
Data Structure Designdesign-dslinked-listsarrays - Data Structure DesignMediumAuto-gradedStream Merging Iterator for Two Ordered Sequences
Simulate a stateful iterator that lazily combines two strictly sorted sequences into a single sorted, duplicate-free stream using constant space.
Data Structure Designdesign-dsarraysheaps-sorting - Data Structure DesignMediumAuto-gradedWildcard Word Dictionary Simulator
Simulate a word store that answers pattern queries where '.' stands for any single letter, which is best handled with a prefix tree and a depth-aware traversal.
Data Structure Designtriedesignwildcarddfs - Data Structure DesignMediumAuto-gradedSliding Window Stream Aggregator
Design a memory-efficient real-time streaming data structure to query moving averages over a sliding temporal window.
Data Structure Designsliding-windowdequedesignstream-processing - Data Structure DesignMediumAuto-gradedIn-Memory Bank Ledger with Pending Transfers and Expiry
Simulate an in-memory banking system processing sequential operations, pending transfers with fixed-window expiration, and account activity tracking.
Data Structure DesignData StructuresSimulationDesignHash Table - Data Structure DesignEasyAuto-gradedDuel Resolver: Speed, Types and Chip Damage
Simulate a two-creature duel with fixed speed order, a minimum-damage floor, and a type-advantage multiplier, then return the winner's name.
Data Structure Designsimulationdictionariesfloating-pointgame-logic - Data Structure DesignMediumAuto-gradedSimulate a Stateful Banking Ledger with Queued Payments
Simulate an in-memory banking system handling accounts, balances, scheduled payments via a priority queue, and account merges.
Data Structure Designheaphash-tablesimulationdesign-ds - 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 - 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 - Data Structure DesignMediumAuto-gradedRanking Frequent Event Names Within a Time Window
Simulate a stream of timestamped log events and answer window queries for the k most frequent messages, with ties broken alphabetically, using binary search over a sorted log.
Data Structure Designdesignbinary-searchhash-mapsorting - Data Structure DesignMediumAuto-gradedArticle Reaction Ledger with Recent Reversal Log
Simulate a stream of up/down/clear reactions on articles, maintaining net scores and a bounded log of the three most recent reversals per article, all in constant time per operation.
Data Structure Designhash-mapdequesimulationstate-tracking - Data Structure DesignEasyAuto-gradedRunning Tally per Label from a Replayed Call Log
Replay a log of increment calls and report, for each call, how many times its key has appeared so far, testing hash map counting and a simple operation-dispatch design.
Data Structure Designhash-mapsimulationdesigncounting - Data Structure DesignMediumAuto-gradedFixed-Size Ring Buffer Command Simulator
Simulate a bounded FIFO ring buffer driven by a list of commands, handling wrap-around, full and empty states, and returning each command's result in order.
Data Structure Designdesignqueuering-buffersimulation - Data Structure DesignMediumAuto-gradedExpense Reimbursement Ledger Simulator
Simulate an expense tracking ledger executing sequential API calls with validation and error checks.
Data Structure Designdesign-dsarrayshash-table - Data Structure DesignMediumAuto-gradedNested Undo-Log Session Store with Value Tallies
Simulate an in-memory key-value store with nested transactions, a global commit, and a live per-value key tally, processing a batch of operations and returning each result.
Data Structure Designhash-mapundo-logtransactionssimulation - Data Structure DesignMediumAuto-gradedSimulate an Expiring Key-Value Store with Read-Through Loads
Simulate a time-aware key-value store with expiry, stale entries that stay stored, and a read-through fetch whose loader outcome is given as data, with strict input validation.
Data Structure Designsimulationhash-mapcachevalidation - Data Structure DesignMediumAuto-gradedCanvas Replay with Undo and Redo History
Simulate a pixel canvas with draw, erase, flood fill, undo and redo, returning a canvas snapshot after every command while keeping the history stacks consistent.
Data Structure Designstacksimulationflood-fillundo-redo - Data Structure DesignMediumAuto-gradedPoint-in-Time Set Views from an Operation Log
Simulate a set that processes add, remove, contains and snapshot operations, where each snapshot must be an independent frozen copy of the set at that moment.
Data Structure Designdesignhash-setsnapshotsimulation - Data Structure DesignMediumAuto-gradedSimulate a Fixed-Size Cache Under LRU or LFU Eviction
Replay a list of get/put operations on a bounded cache that evicts by recency or by frequency (ties broken by recency), and return the result of each operation.
Data Structure Designhash-mapordered-dictlrulfu