Katkat

practice a little every day, paws crossed ♡

Software Engineer Interview Questions

Practice 9403 coding, system design and machine learning questions from 546 companies, sorted by role, topic and interview round. Every question has step-by-step hints, a code runner that supports 8 languages and an AI mentor; members also get the full solution walkthrough.

9403
Questions
546
Companies
11
Topics
8
Languages

Showing 301–330 of 2336 results

  • AnthropicMediumSoftware Engineer
    Implement Python LRU cache with varargs

    This question evaluates a candidate's ability to implement an LRU caching mechanism in Python, including decorator design, argument canonicalization for positional args, *args, and **kwargs, handling unhashable inputs, eviction semantics, cache metadata operations (clear, cache_info), and JSON-based persistence and versioning.

    Coding & AlgorithmsOnsite
  • AnthropicMediumSoftware Engineer
    Implement a Banking System

    This question evaluates skills in designing and implementing a stateful in-memory banking system, covering account modeling, transfer lifecycle and expiration handling, balance management, and tracking aggregate outgoing amounts.

    Coding & AlgorithmsOnsite
  • AnthropicMediumSoftware Engineer
    Implement a Least-Recently-Used Cache

    This question evaluates a candidate's ability to design and implement an efficient in-memory cache with eviction behavior, testing understanding of data structure selection, state management, and time/space complexity under capacity constraints.

    Coding & AlgorithmsOnsite
  • AnthropicHardSoftware Engineer
    Implement a Longest-Match Tokenizer

    Design and implement a greedy longest-match text tokenizer that validates vocabulary, supports configurable unknown-token coalescing, and emits token IDs alongside their exact substring matches.

    Coding & AlgorithmsOnsitetriestringnlp
  • AnthropicHardSoftware Engineer
    Implement a hierarchical file store

    This problem tests your ability to design a hierarchical file system data structure and implement operations for directory traversal, file manipulation, and path normalization.

    Coding & AlgorithmsOnsiteTreeTrieData Structures
  • AnthropicHardSoftware Engineer
    Implement and analyze custom attention

    This question evaluates implementation and analysis skills for scaled dot-product attention, testing competencies in efficient tensorized PyTorch coding, numerical stability and mixed-precision handling, masking semantics (causal and padding), multi-head shape correctness, and unit-test validation including gradient and edge-case behavior.

    Machine LearningOnsite
  • AnthropicMediumSoftware Engineer
    Implement and derive backprop from scratch

    This question evaluates understanding and practical implementation of neural network fundamentals, specifically analytic backpropagation and gradient derivation, numerically stable binary cross-entropy computation, parameter initialization, gradient descent updates, and gradient checking.

    Machine LearningOnsite
  • AnthropicMediumSoftware Engineer
    Implement crawler, dedup, and persistent LRU

    This interview question evaluates algorithm design, data structures, correctness, complexity, edge cases, and implementation details in a realistic interview setting. A strong answer for Implement crawler, dedup, and persistent LRU states assumptions, handles edge cases, explains trade-offs, and shows how to validate the result clearly.

    Coding & AlgorithmsOnsite
  • AnthropicMediumSoftware Engineer
    Implement file deduplication at scale

    Implement streaming file deduplication that filters by size, fingerprint and hash, then compares bytes to rule out hash collisions. It covers large-file chunking, batched disk I/O, parallelizing across cores or machines, a dry-run report, and hard links that never cross devices. Follow-ups turn it into a command-line tool that handles symbolic links, unreadable files, error cases, and options to move or delete duplicates.

    Coding & AlgorithmsOnsite
  • AnthropicHardSoftware Engineer
    Implement staircase printing and distributed mode/median

    This set of problems evaluates implementation correctness and attention to formatting for a staircase-printing routine alongside distributed-algorithms reasoning for computing a global mode/median, testing algorithmic thinking, I/O handling, synchronization, and communication-cost trade-offs in the Coding & Algorithms domain.

    Coding & AlgorithmsOnsite
  • AnthropicMediumSoftware Engineer
    Implement thread-safe blocking queue

    This question evaluates competency in concurrent programming, synchronization primitives, and implementation of thread-safe bounded blocking queues within the Coding & Algorithms domain.

    Coding & AlgorithmsOnsite
  • AnthropicMediumSoftware Engineer
    In-Memory Key-Value Database with Nested Transactions

    Design an in-memory key-value store supporting nested transactions with begin, commit, rollback, get, set, and delete operations.

    Coding & AlgorithmsOnsiteData StructuresStackDesign
  • AnthropicMediumSoftware Engineer
    LRU Cache

    This question tests the ability to combine a hash map and a doubly linked list to implement an LRU cache with O(1) performance for both get and put operations.

    Coding & AlgorithmsOnsiteHash MapDoubly Linked ListDesign
  • AnthropicHardSoftware Engineer
    Lead a Project Retrospective Discussion

    Lead a project retrospective that explains the hardest challenge, its root cause, and the alternatives considered. Separate personal ownership from team effort, support outcomes with evidence, acknowledge limitations, and show how the lesson changed later decisions.

    Behavioral & LeadershipOnsite
  • AnthropicMediumSoftware Engineer
    Make a Web Crawler Concurrent with Thread-Safe Visited State

    Convert a sequential crawler to bounded concurrency using atomic URL reservation, explicit retry state, and completion detection that accounts for active fetches.

    Software Engineering FundamentalsOnsite
  • AnthropicMediumSoftware Engineer
    Mode, Median and Sort Across 10 Nodes with Send/Receive While Minimizing Traffic

    Integers are spread across 10 nodes that communicate only by sending and receiving messages. Write the per-node programs that compute the exact mode, the median and a globally sorted order while sending as little data as possible. It tests MapReduce-style aggregation, distributed selection, sample sort and message coordination.

    Software Engineering FundamentalsOnsite
  • AnthropicHardSoftware Engineer
    Optimize a compute kernel with a simulator

    This question evaluates performance engineering and low-level kernel optimization competencies, including profiling, data-layout and instruction-level techniques, correctness verification, and benchmark-driven measurement within the System Design domain.

    System DesignOnsite
  • AnthropicMediumSoftware Engineer
    Parallelize a Directory Walker With Thread-Safe Visited Tracking

    Turn a sequential directory walker into a bounded-concurrency one, using an atomic reserve-before-expand step so two worker threads that reach the same directory at once never process it twice.

    Software Engineering FundamentalsOnsiteconcurrencythreadingshared-state
  • AnthropicMediumSoftware Engineer
    Path Resolution with Symbolic Links

    Implement a filesystem path resolution function that normalizes paths containing '.', '..', and symbolic links while detecting cycles.

    Coding & AlgorithmsOnsitestring parsingstacksimulation
  • AnthropicMediumSoftware Engineer
    Performance-Model a Sharded Matrix Multiply: FLOPs, Memory, Network and Roofline

    Model the performance of a matrix multiplication by hand: count floating-point operations, memory bytes and network bytes, apply the roofline model to decide what bounds it, and compare sharding along each dimension across several accelerators. It tests arithmetic intensity, collective communication costs and quantitative reasoning.

    ML System DesignOnsite
  • AnthropicHardSoftware Engineer
    Present a Technical Project to a Cross-Functional Audience

    Tests your ability to present a complex engineering effort to a cross-functional technical panel, balancing architectural depth, consequential trade-offs, and rigorous post-launch reflection.

    Behavioral & LeadershipOnsitebehavioralproject-deep-divecommunication
  • AnthropicMediumSoftware Engineer
    Present project and answer behaviorals

    This question evaluates leadership and behavioral competencies alongside technical communication skills, including project ownership, system architecture articulation, trade-off reasoning, metrics-driven impact measurement, stakeholder management, and mentorship.

    Behavioral & LeadershipOnsite
  • AnthropicHardSoftware Engineer
    Reason About Delaying an AI Breakthrough Under Uncertain Risk

    Reason about an AI breakthrough under uncertain risk by separating research and deployment, weighing evidence and reversibility, and addressing competitive pressure consistently.

    Behavioral & LeadershipOnsite
  • AnthropicMediumSoftware Engineer
    Repairing a Difficult Working Relationship

    Tests emotional intelligence, self-awareness, and constructive conflict resolution when collaborating with engineering peers or cross-functional partners under pressure.

    Behavioral & LeadershipOnsitebehavioralconflict-resolutioncollaboration
  • AnthropicMediumSoftware Engineer
    Resolve a Package Dependency Graph with Concurrent Fetches

    Discover a package's transitive dependency graph from a slow, flaky registry, first with a sequential BFS and then with a bounded pool of worker threads. Tests atomic visited-set reservation, explicit retry state, and correct termination detection with in-flight work.

    Software Engineering FundamentalsOnsiteconcurrencythreadinggraph-traversal
  • AnthropicMediumSoftware Engineer
    Respond to a Hypothetical Loss of Employer Equity Value

    Tests how candidates navigate extreme organizational adversity, balance personal financial realities against mission alignment, and evaluate their long-term commitment and team responsibilities during a company crisis.

    Behavioral & LeadershipOnsiteBehavioralLeadershipAdversity Management
  • AnthropicMediumSoftware Engineer
    Resume Project Deep Dive and Prioritizing Too Many Tasks at Once

    A behavioral interview question in two parts: a deep dive into a project from your resume, where the interviewer probes design decisions, your own contribution and results, and a question about a time you had more tasks than you could finish. It tests technical depth, prioritization criteria and how you communicate trade-offs to stakeholders.

    Behavioral & LeadershipOnsite
  • AnthropicMediumSoftware Engineer
    Reuse Work Across Multiprocess Image Pipelines

    Implement a thread-safe pipeline execution engine that caches deterministic intermediate prefix results, deduplicates concurrent in-flight computations, and manages a bounded LRU cache.

    Software Engineering FundamentalsOnsiteconcurrencycachingsystem-design
  • AnthropicMediumSoftware Engineer
    Review a Batched GPU Inference API Design Doc: Flaws, Throughput, Mixed-Model GPUs

    Review a design document for a batched GPU inference API and find its flaws in load balancing, batching, caching, retries and admission control. Then compare theoretical and achievable throughput at 100 ms per batch and 10,000 QPS, and schedule a large and a small model on one 8-GPU pool.

    System DesignOnsite
  • AnthropicHardSoftware Engineer
    Review an inference API design for scale

    This question tests a candidate's ability to critically evaluate ML system designs for production-scale inference APIs, covering multi-tenancy, GPU resource constraints, and streaming token delivery. It assesses architectural reasoning across reliability, latency trade-offs, and capacity planning in the ML Systems domain.

    ML System DesignOnsite