KatInterview

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

Interview Practice Problems

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

6019
Problems
2229
Auto-graded
15
Topics
276
Added today

Showing 871–900 of 6019 results

  • Arrays & HashingEasyAuto-graded
    Build a Route Map Request with Markers and Striped Segments

    Convert longitude-first route points into a map request with start and end markers and path groups of ten segments that alternate colors and share boundary points.

    Arrays & Hashingarraysgroupingtransformationdictionaries
  • BehavioralMediumModel answer
    Pushing Back on a Technical Call and Then Backing the Decision

    Tell a structured story about disagreeing with a manager or stakeholder on a technical direction or priority, how you made your case, and how you supported the final decision.

    Behavioralbehavioralconflict-resolutionstakeholder-managementdisagree-and-commit
  • Statistics & ExperimentsMediumModel answer
    Pick a Consumer App: Metrics, Experiment, Launch Call

    Choose a consumer app, break down how it makes money and who it competes with, define key and guardrail metrics, then design and decide on an A/B test for one improvement.

    Statistics & Experimentsproduct-analyticsab-testingmetricspower-analysis
  • BehavioralMediumModel answer
    Behavioral Prep: Coaching a Struggling Peer and Unblocking a Critical Project

    Prepare two contrasting stories: supporting a struggling teammate without taking over, and driving a high-priority project past a major blocker while managing stakeholder expectations.

    Behavioralbehavioralleadershipstakeholder-communicationownership
  • Data Structure DesignMediumModel answer
    Build a Terminal Block-Stacking Game Engine

    Design a testable, terminal-friendly engine for a falling-block puzzle on a 10x20 grid, covering movement, rotation, gravity, locking, line clearing and game over.

    Data Structure Designgame-logicstate-machinesimulationobject-oriented-design
  • Statistics & ExperimentsHardModel answer
    Measuring a Feed Redesign Launched With No Holdout Group

    Estimate the impact of a feed change shipped without a control group, compare matching with propensity weighting, audit an A/B test, pick module metrics, and debug a CTR drop.

    Statistics & Experimentscausal-inferencepropensity-scoreab-testingmetrics
  • System DesignMediumModel answer
    Layering a Big-Data Analytics Stack: Lake, Engine, and Serving Tier

    Decide how to combine HDFS, Spark, Hive and SQL Server into a pipeline for 500 TB of logs, analyst SQL, fast executive dashboards and strict governance, and justify what to leave out.

    System Designdata-warehousehadoopsparkhive
  • Arrays & HashingMediumAuto-graded
    Bayesian Inference for Coin Flipping

    Evaluate posterior coin probabilities, posterior predictive likelihoods, and expected stopping times following observed heads.

    Arrays & Hashingprobabilitybayes-theoremexpected-valuebayesian-inference
  • Data Structure DesignMediumAuto-graded
    Deadline-First Job Queue with Prerequisite Gating

    Simulate a job queue where jobs unlock after their prerequisites are consumed, always serving the earliest-deadline unlocked job; tests heaps, dependency counting, and tie-breaking.

    Data Structure Designheaptopological-sortgraphsimulation
  • Statistics & ExperimentsMediumModel answer
    Did a New Dispatch Algorithm Cut Rider Wait Times? A/B Analysis

    Analyze a city-level dispatch A/B test in pandas, run a Welch t-test on wait time, and discuss clustering, selection bias, effect size, and a stronger experiment design.

    Statistics & Experimentsab-testingwelch-t-testpandasclustered-data
  • System DesignMediumModel answer
    Spring Boot 3 and Java 21 Drill-Down on a Small REST Service

    Defend a small Spring Boot 3 / Java 21 REST service: explain startup, auto-configuration, proxies, modern Java features, and design and concurrency trade-offs.

    System Designspring-bootjava-21virtual-threadsdependency-injection
  • Machine LearningMediumModel answer
    Generalization Gaps and the Mechanics of Transformer Attention

    Diagnose and fix overfitting in linear and deep models, then explain self-attention (queries, keys, values, softmax weights) and why and how Transformers inject position information.

    Machine Learningoverfittingregularizationtransformersself-attention
  • Data Structure DesignMediumAuto-graded
    Two-Tier Fixed-Window Request Throttle Simulator

    Simulate a throttle that enforces a shared limit and a per-key limit over epoch-aligned fixed windows, with lazy reset and a defined precedence between the two rejection reasons.

    Data Structure Designrate-limiterfixed-windowhash-mapsimulation
  • Trees & GraphsMediumModel answer
    Robot Navigation on a Hidden Grid with DFS and Backtracking

    Guide a robot through a map it can only discover step by step, reaching the target with no repeated visits, real backtracking, and a clear result when the target is unreachable.

    Trees & Graphsdfsbacktrackinggraph-traversalgrid
  • System DesignHardModel answer
    Struct Layout and Binary Compatibility in C++

    Explain how alignment and padding determine object size and layout in C++, and why the C++ ABI breaks easily across toolchains, with practical strategies for keeping binary interfaces stable.

    System Designcppmemory-layoutalignmentabi
  • Trees & GraphsEasyAuto-graded
    Locate the Universally Followed Silent Guest

    Find the one node in a directed relation that everyone points to and that points to nobody, using a linear elimination pass followed by verification.

    Trees & Graphsgraphcelebrity-problemtwo-passelimination
  • BehavioralEasyModel answer
    Fixing a Broken Test and Release Process: A Story to Tell

    Walk through a real case where you spotted a weak testing or release process, changed it, won over teammates, and showed measurable improvement.

    Behavioralbehavioralqaprocess-improvementstakeholder-management
  • Data Structure DesignEasyAuto-graded
    Simulate a Task Board with Id-Keyed Commands

    Process a batch of add, update, get and delete commands against an in-memory task store keyed by id, returning one result per command.

    Data Structure Designhash-mapsimulationdesigndictionary
  • Statistics & ExperimentsHardModel answer
    Launch Call When Cross-Account Notifications Cannibalize Usage

    An A/B test shows notification metrics rising but usage falling on other accounts of multi-account users. Frame the trade-off, estimate long-term value, propose mitigations, and plan monitoring.

    Statistics & Experimentsexperimentationproduct-sensecannibalizationlaunch-decision
  • Stacks & QueuesMediumAuto-graded
    Wait Time Until a Strictly Larger Sensor Value

    Find, for each position in a sequence, the distance to the next strictly larger element, using a monotonic stack to achieve linear time.

    Stacks & Queuesmonotonic-stackarraysnext-greater-element
  • Trees & GraphsMediumAuto-graded
    Teardown Sequencing with Nested Ownership and Extra Prerequisites

    Find the lexicographically smallest valid ordering of nodes under child-before-parent and extra precedence rules, or report impossibility when the rules contradict.

    Trees & Graphstopological-sortheapcycle-detectiongraph
  • SQL & DataEasyAuto-graded
    Daily Spend Ranking for Frequent Payers

    Filter users by total event count, then rank each user's payments within each calendar day by amount using competition ranking (ties share a rank, then a gap).

    SQL & Datawindow-functionsgroupingrankingsorting
  • BehavioralMediumModel answer
    Walking Through Your Highest-Impact Project of the Past Three Years

    Describe one recent project you drove, covering target, constraints, decisions, risk, measured before/after results, accepted trade-offs and what you reused later.

    Behavioralbehavioralimpactmetricstrade-offs
  • System DesignMediumModel answer
    Weighing an AI Assistant for Insurance Policyholder Support

    Argue the value of putting an automated assistant in front of policyholders, tying each benefit to a mechanism and a metric, then weigh it against risks around claims and payouts.

    System Designproduct-strategychatbotinsurancemetrics
  • Data Structure DesignMediumAuto-graded
    Longest Dictionary Word Ending With a Given Tail

    Answer batches of suffix queries over a word list, returning the longest match with lexicographic tie-breaking, using a reversed-word trie with cached best words.

    Data Structure Designtriestringssuffixpreprocessing
  • StringsMediumAuto-graded
    String Array Framing and Round-Trip Encoding

    Design a robust serialization scheme that packs a list of arbitrary strings into a single string and successfully reconstructs it without ambiguity.

    Stringsstringsarraysdesign-ds
  • Machine LearningHardModel answer
    Debiasing Click Logs for Ranking: Propensities, IPS, Offline Eval

    Design a pipeline that models, estimates and corrects position bias in click-trained feed rankers, then evaluates a new ranker offline using only logged impressions.

    Machine Learningposition-biaslearning-to-rankinverse-propensity-scoringcounterfactual-evaluation
  • Trees & GraphsMediumModel answer
    Sliding Block Minimums and Dependency-Ordered Cooking Plan

    Compute the minimum of every K x K window in a grid, then order recipes so that every derived ingredient is made before the dish that uses it, detecting cycles.

    Trees & Graphstopological-sortmonotonic-dequesliding-windowkahns-algorithm
  • Arrays & HashingMediumAuto-graded
    Longest Strictly Rising Window After One Edit

    Find the longest contiguous strictly increasing window in an integer array after replacing at most one element with any integer, using prefix and suffix run lengths.

    Arrays & Hashingarrayssliding-windowprefix-suffixdynamic-programming
  • Data Structure DesignHardAuto-graded
    Seat Row Simulator: Leftmost Block Booking and Group Release

    Simulate a row of seats where each booking takes the leftmost free block of a given length and a release frees all of a group's seats, efficiently on large inputs.

    Data Structure Designsegment-treelazy-propagationsimulationinterval-bookkeeping