KatInterview

practice a little every day — you've got this ♡

Interview Practice Problems

Practice 6029 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.

6029
Problems
2232
Auto-graded
15
Topics
273
Added today

Showing 4921–4950 of 6029 results

  • StringsHardAuto-graded
    Detect a Contiguous Block Inside an Integer Sequence

    Tests the ability to determine whether one integer array appears as an unbroken, in-order block inside a larger array using linear-time pattern matching.

    StringsKMPpattern matchingarrayssubsequence
  • Arrays & HashingMediumAuto-graded
    Collect Characters by Walking a Grid

    Tests grid traversal with directional commands, run-length encoding, and boundary/obstacle validation.

    Arrays & Hashingmatrixsimulationstring-building
  • Machine LearningMediumModel answer
    Evaluate LLM Output Quality and Build a Groundedness Scorer

    Design a full LLM evaluation system covering metrics, A/B comparison, hallucination detection, and a Python groundedness scorer that flags unsupported sentences.

    Machine Learningllmevaluationhallucination-detectionrag
  • Trees & GraphsMediumAuto-graded
    Find Valid Completion Sequence for Dependent Tasks

    Tests understanding of topological sorting, dependency graph modeling, and cycle detection in directed acyclic graphs.

    Trees & Graphstopological-sortgraphsbfscycle-detection
  • BehavioralMediumModel answer
    Holding the Line: Disagreeing with a Senior Stakeholder on a Launch

    Describe a specific incident where you pushed back on a senior stakeholder over a data product launch, showing how you quantified risk, influenced without authority, and committed to the outcome.

    Behavioralleadershipstakeholder-managementinfluencerisk-communication
  • Greedy & IntervalsMediumAuto-graded
    Maximize Pay by Filling Gaps in a Shift Schedule

    Tests greedy reasoning and run-based reformulation to optimally spend a limited number of schedule changes for maximum earnings with streak bonuses.

    Greedy & Intervalsgreedydynamic-programmingarrays
  • Data Structure DesignMediumAuto-graded
    Cart History: Undo and Redo Item Changes

    Design a cart with reversible add/remove operations, tracking change history with undo/redo stacks.

    Data Structure Designdata-structuresstackstate-management
  • Data Structure DesignMediumAuto-graded
    Hierarchical Resource Tree Operations

    Tests tree manipulation with parent-child relationships, path reconstruction, and cycle prevention during node relocation.

    Data Structure Designtreeshash-mapsgraphscycle-detection
  • System DesignMediumModel answer
    Idempotent Reminder and Queue-Based Availability Notifications

    Design a backend notification system for item-due reminders and FIFO waitlist alerts that survives retries, crashes, and mutable state without sending duplicates.

    System Designidempotencynotificationsqueuesconcurrency
  • StringsHardAuto-graded
    Find Next Larger Palindrome Within Digit Limit

    Tests constructing the immediate successor palindrome by manipulating the left half, handling carries, length transitions, and an upper bound.

    Stringspalindromesstring-manipulationgreedy
  • Heaps, Sorting & SearchMediumAuto-graded
    Combine K Sorted Sequences into One

    Tests whether a candidate can use a min-heap to efficiently merge multiple sorted lists into a single sorted output in O(N log k) time.

    Heaps, Sorting & Searchheapmergesorting
  • StringsMediumAuto-graded
    Character Removal Anagram Matching

    Tests string manipulation and character frequency analysis to determine if two strings can become anagrams through optional single-character removal.

    Stringshash-mapcountinganagrams
  • Trees & GraphsMediumModel answer
    Recursive Maximum Search in an Arbitrary Binary Tree

    Write a recursive function that traverses a binary tree to locate the largest integer value, accounting for null pointers and negative-only trees.

    Trees & Graphsrecursionbinary-treetraversaledge-cases
  • Trees & GraphsEasyAuto-graded
    Paint Bucket: Recolor a 4-Connected Region in a Grid

    Tests BFS/DFS grid traversal by spreading a new color through all 4-directionally connected cells sharing the starting cell's original color.

    Trees & Graphsbfsgridgraph-traversal
  • System DesignHardModel answer
    Build a Sync Engine for Multi-Scope IDE Configuration

    Design a configuration service that merges settings from org, team, workspace, user, and local scopes, syncs across devices, and handles offline edits with conflict resolution.

    System Designdistributed-systemsconflict-resolutionversioning
  • BehavioralMediumModel answer
    Articulating Career Direction in a Recruiter Screen

    Craft a compelling narrative connecting your background to a target role while explaining your motivation for change in a recruiter phone screen.

    Behavioralcommunicationcareer-narrativemotivationinterview-prep
  • BehavioralMediumModel answer
    Walk Me Through Your Highest-Impact Engineering Project

    Describe a project you owned that produced measurable results, covering the architecture, your specific contributions, trade-offs, and how you quantified success.

    Behavioralcommunicationsystem designownershiptrade-offs
  • System DesignEasyModel answer
    Transitioning an Experimental System to Production

    Describe your approach for evolving an experimental prototype into a production-ready system with appropriate reliability, security, and operational support.

    System Designproduction-readinesssoftware-engineeringoperational-excellence
  • Data Structure DesignMediumAuto-graded
    Process Event Listener Operations

    Tests understanding of the observer pattern through ordered listener management, callback registration/removal, and event dispatch simulation.

    Data Structure Designobserver-patterndata-structuresstate-management
  • Machine LearningHardModel answer
    Building a Production-Ready Churn Prediction System

    Design and debug a user retention model: fix temporal leakage, implement proper validation, calibrate for business decisions, and establish monitoring.

    Machine Learningsupervised-learningdata-leakagemodel-evaluationcalibration
  • Trees & GraphsMediumAuto-graded
    Cluster Interchangeable Words by Surrounding Context

    Tests context hashing, union-find for transitive closure, and precise output formatting to group words that are mutually substitutable in identical four-word windows.

    Trees & Graphsunion-findhashingstrings
  • BehavioralMediumModel answer
    Fermi Estimation & Product Metrics for a Collaboration Tool

    Decompose two market-sizing problems and define three measurable product metrics for a real-time document editor.

    Behavioralproduct-sensemarket-sizingmetricsfermi-estimation
  • Trees & GraphsMediumAuto-graded
    Shortest Path Through a Network With Hazardous Nodes

    Tests BFS on filtered graphs and Dijkstra with lexicographic two-criteria cost to navigate networks while minimizing hazardous-node visits then total hops.

    Trees & Graphsbfsdijkstrashortest-path
  • StringsMediumAuto-graded
    Maximum Unique Character Window Length

    Tests sliding window technique with hash map indexing to efficiently find the longest substring with all distinct characters.

    Stringssliding-windowhash-maptwo-pointers
  • Data Structure DesignHardAuto-graded
    Live String Index Store with Closest-Match Queries

    Tests ability to design a data structure that supports streaming character appends, point updates, and O(log N) nearest-occurrence queries over a mutable string.

    Data Structure Designordered-settreapbinary-search-treedesign
  • Data Structure DesignHardAuto-graded
    Simulate a Time-Aware Key-Value Store with Transactions

    Tests implementation of an in-memory store combining TTL expiration, a logical clock, and atomic single-transaction semantics with rollback.

    Data Structure Designhash-maptransactionssimulation
  • Arrays & HashingMediumAuto-graded
    Reorganize Array Elements by Hash-Based Bucket Assignment

    Tests understanding of parallel counting, prefix sums, and scatter operations to group array elements into contiguous buckets.

    Arrays & Hashingcountingprefix-sumpartitioning
  • Arrays & HashingMediumAuto-graded
    Difference in Proportions Confidence Interval

    Tests understanding of statistical inference by computing a confidence interval for the difference between two independent proportions.

    Arrays & Hashingstatisticshypothesis-testingconfidence-intervalsexperimental-design
  • Trees & GraphsMediumAuto-graded
    Assemble a Binary Tree from Two Traversals, Output by Level

    Tests whether a candidate can reconstruct a unique binary tree from its preorder and inorder sequences and serialize the result breadth-first with null markers.

    Trees & Graphsbinary-treetraversalBFSiterative
  • Math & Bit ManipulationMediumAuto-graded
    Count Days Between Two Dates

    Tests efficient calendar arithmetic by computing date intervals without iteration, requiring leap year logic and modular reasoning.

    Math & Bit Manipulationmathcalendarmodular-arithmetic