practice a little every day — you've got this ♡
Coding Interview Problems
Practice 6016 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.
- 6016
- Problems
- 2229
- Auto-graded
- 15
- Topics
- 274
- Added today
Showing 1351–1380 of 2128 results
- Arrays & HashingMediumAuto-gradedAlternating Chain Assembly from Both Ends
Tests two-pointer simulation with alternating turns, conditional greedy selection rules, tie-breaking logic, and strict-increase constraints.
Arrays & Hashingsimulationtwo-pointersarrays - Data Structure DesignHardAuto-gradedIP Access Control with CIDR Matching
Tests binary trie implementation for efficient IP prefix matching with CIDR notation and rule subsumption optimization.
Data Structure Designtriebit-manipulationnetwork-programming - Trees & GraphsMediumAuto-gradedConvert Nested Dictionary to Dot-Separated Keys
Tests ability to traverse nested data structures and transform hierarchical key-value pairs into a flat representation using path notation.
Trees & Graphsrecursioniterationdictionarytree-traversal - Arrays & HashingHardAuto-gradedDifference-in-Differences Estimator with Baseline Gap Check
Tests understanding of causal inference mechanics by computing a DID treatment effect and flagging baseline imbalance from panel observations.
Arrays & Hashingcausal-inferencedata-analysisdifference-in-differences - Heaps, Sorting & SearchMediumAuto-gradedBinary Search Over Date-Filtered Content Flags
Tests whether a candidate can isolate records by category and then apply binary search to efficiently locate all entries within an inclusive date window.
Heaps, Sorting & Searchbinary-searchsortingdata-manipulation - Math & Bit ManipulationMediumAuto-gradedFrequency Peaks and Prime Extraction
Tests frequency counting with tie-aware mode detection and prime identification via sieve, including edge cases for unique values and non-prime inputs.
Math & Bit Manipulationhash-mapsieve-of-eratosthenesfrequency-counting - Arrays & HashingHardAuto-gradedData-Driven Fare Policy Rule Engine
Evaluate stored fare and per-driver policy rules over a trip table with generic field/operator conditions and exact integer-cent sums.
Arrays & Hashinghash-mapsortingrule-enginesimulation - Arrays & HashingMediumAuto-gradedTransform a Sorted Array with a Quadratic
Evaluate a quadratic expression at every element of a sorted array and emit the results in ascending order in linear time.
Arrays & Hashingtwo-pointerssortingmathmonotonic - StringsEasyAuto-gradedCluster Words by Letter Inventory
Tests whether you can use a canonical character-frequency key and a hash map to partition a list of strings into anagram groups in linear time.
Stringshash-mapstringsanagrams - Data Structure DesignMediumAuto-gradedParcel Attribute Store with TTL and Prefix Queries
Simulate a timestamped key-value attribute store with overwrite, conditional update, sorted prefix listing, and per-attribute expiry.
Data Structure Designhash-mapsimulationsortingexpiry - Arrays & HashingHardAuto-gradedAll MEX Values After One Optional Increment
Find every possible MEX after incrementing at most one array element by 1, respecting an upper-bound constraint.
Arrays & Hashingarraysgreedymathcase-analysis - Arrays & HashingEasyAuto-gradedCount Strictly Rising Signal Windows
Count how many contiguous subarrays of length exactly k have strictly increasing values in a signal array.
Arrays & Hashingarrayssliding-windowcounting - Data Structure DesignMediumAuto-gradedReplayable Library Lending Operations
Simulate a book catalog with case-insensitive title/author search and atomic borrow/return state transitions replayed from an operation log.
Data Structure Designhash-mapsimulationstring-matchingstate-machine - Data Structure DesignHardAuto-gradedRolling-Window Chat Activity Tracker
Build a bounded-memory sliding-window aggregator answering distinct-chat, distinct-user, and message-total queries from an operation log in amortized O(1).
Data Structure Designsliding-windowdequehash-mapreference-counting - Arrays & HashingMediumAuto-gradedLength of the Longest Run of Consecutive Integers
Tests whether a candidate can find the longest chain of consecutive integers in an unsorted array in linear time using a hash set.
Arrays & Hashinghash-setarrayssequences - Greedy & IntervalsMediumAuto-gradedCount Active Surveillance Cameras at Each Minute
Tests the sweep-line technique by computing, for each minute in a query list, how many camera recording intervals are active at that exact moment.
Greedy & Intervalssweep lineintervalsgreedysorting - Heaps, Sorting & SearchMediumAuto-gradedFirst Flagged Build in a Deployment Pipeline
Tests whether a candidate can recognize a monotonic predicate and apply binary search to find the first transition point without comparing version strings.
Heaps, Sorting & Searchbinary-searcharraysmonotonic-predicate - StringsEasyAuto-gradedCount Single-Character Occurrences in a String
Tests whether a candidate can scan a string and tally exact, case-sensitive matches for a given character, including edge cases like empty input and repeated characters.
Stringsstringscountingcase-sensitivity - Data Structure DesignMediumAuto-gradedBilling Reconciliation: Match Payments to Invoices in Three Stages
Tests incremental lookup design by matching payments to invoices via explicit ID, then earliest-dated exact-amount fallback, then a forgiveness range, with closed-invoice tracking throughout.
Data Structure Designhash-mapheapsegment-tree - Stacks & QueuesEasyAuto-gradedBalanced Delimiter Validation with a Stack
Decide whether a bracket-only string is properly nested and matched, using a LIFO stack of pending openers.
Stacks & Queuesstackstringsparsing - Arrays & HashingMediumAuto-gradedLongest Strictly Increasing Contiguous Run
Tests whether a candidate can scan an array in a single linear pass to find the length of the longest strictly increasing contiguous run.
Arrays & Hashingarrayssliding-windowgreedy - Trees & GraphsMediumAuto-gradedColumn-Ordered Tree Values From a Level-Order Array
Bucket level-order tree nodes by column, then sort each column by depth and value to produce the grouped output.
Trees & Graphsbinary-treebreadth-first-searchsortinghash-map - StringsMediumAuto-gradedReconstruct Digit Sequence from a Jumbled Letter Pool
Tests whether a candidate can decode digit counts from a scrambled multiset of English number-word letters using systematic letter-frequency elimination.
Stringsstringshash-mapgreedy-intervals - Arrays & HashingMediumAuto-gradedFind Gaps in Traffic Segment Assignments
Tests set-based membership filtering over a bounded integer range, with duplicate and out-of-bounds input handling.
Arrays & Hashingsetsfilteringranges - Arrays & HashingMediumAuto-gradedCheck for Subarray Summing to Target
Tests the ability to use prefix sums and a hash set to detect whether any contiguous slice of an array sums to a given value.
Arrays & Hashingprefix-sumhash-setsubarray - Arrays & HashingMediumAuto-gradedLocate Symbol-Structure Templates in a Number Grid
Tests whether a candidate can slide a letter-template over an integer grid and detect every position where symbols and values form a valid one-to-one correspondence.
Arrays & Hashinghash-mappattern-matchingmatrixisomorphism - Arrays & HashingHardAuto-gradedBayesian Coin Identification from Flip Observations
Compute exact posterior probabilities over three weighted coins from a sequence of flips, plus the predictive probability the next flip is heads.
Arrays & Hashingbayes-theoremprobabilityfractionsposterior-predictive - Data Structure DesignEasyAuto-gradedBuild a Fixed-Capacity Recency-Ordered Cache
Tests whether you can design a cache that evicts the least-recently-touched entry in O(1) time using a hash map paired with an ordered structure.
Data Structure Designhash-maplinked-listcacheOrderedDict - Data Structure DesignMediumAuto-gradedUnified Entity Log with Mergeable ID Groups
Tests ability to design a data structure that resolves multiple system-assigned IDs to a single entity and returns a chronologically merged observation history.
Data Structure Designunion-finddesignsorting - Greedy & IntervalsEasyAuto-gradedBudget Shopping from Array Suffix
Tests greedy selection with precomputation, prefix sums, and binary search to maximize item counts under budget constraints.
Greedy & Intervalsgreedybinary-searchprefix-sumsorting