Katkat

practice a little every day, paws crossed ♡

Coding & Algorithms 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 2581–2610 of 3276 results

  • ShopifyMediumData Scientist
    Implement Cosine Similarity Function for String Vectors

    This question evaluates understanding of vector-space similarity and text representation by asking for a cosine similarity computation over string-derived vectors, testing coding and algorithmic skills relevant to data science and text processing.

    Coding & AlgorithmsTechnical Screen
  • ShopifyMediumMachine Learning Engineer
    Implement URL Shortening Codec

    This question evaluates understanding of hashing, encoding, state management, and collision-handling strategies for creating a consistent mapping between long and short URLs, testing competencies in data structures, algorithms, and simple system design within the Coding & Algorithms domain.

    Coding & AlgorithmsOnsite
  • ShopifyMediumMachine Learning Engineer
    Implement a Capacity-Bounded Cache

    This question tests the ability to implement a Least Recently Used (LRU) cache, requiring efficient O(1) time complexity for both data retrieval and insertion through the combination of a hash map and a doubly linked list.

    Coding & AlgorithmsTechnical ScreenHash MapLinked ListCache
  • ShopifyEasySoftware Engineer
    Implement a multi-rover Mars controller

    This question evaluates a candidate's ability to implement stateful command parsing, entity management for multiple rovers, and collision-avoidance on an unbounded 2D grid, emphasizing deterministic simulation, input/output specification, and robust handling of invalid operations.

    Coding & AlgorithmsTechnical Screen
  • ShopifyMediumSoftware Engineer
    Implement an In-Memory File System

    Implement an in-memory file system with absolute and relative path resolution, sorted listing, directory changes, creation, and removal. Enforce deterministic error codes, atomic validation, recursive deletion rules, and protection for the current directory and its ancestors.

    Coding & AlgorithmsOnsite
  • ShopifyMediumData Scientist
    Implement an LRU Cache

    This question tests the ability to combine a hash map and a doubly linked list to achieve constant-time performance for cache operations.

    Coding & AlgorithmsTechnical ScreenHash MapDoubly Linked ListCache
  • ShopifyMediumMachine Learning Engineer
    Implement an interactive CLI class with tests

    This question evaluates object-oriented design, command-line interface implementation, persistent state management, input validation and error logging, extensibility for new commands, comprehensive unit testing, and continuous integration configuration.

    Coding & AlgorithmsOnsite
  • ShopifyEasySoftware Engineer
    Implement cache and gift assignment system

    This two-part exercise evaluates a candidate's competence in designing efficient in-memory data structures with correct eviction semantics (bounded LRU cache with amortized O(1) operations) and in implementing randomized permutation algorithms and input/output handling for derangement-based Secret Santa assignments from CSV input.

    Coding & AlgorithmsTechnical Screen
  • ShopifyEasyData Scientist
    Infer and justify non-trivial sequence patterns

    This question evaluates mathematical reasoning, sequence inference, and pattern-recognition competency by asking the solver to identify governing rules and justify missing terms across numeric sequences and a small grid.

    Coding & AlgorithmsTechnical Screen
  • ShopifyMediumMachine Learning Engineer
    Simulate a rover fleet

    This problem tests your ability to manage state in a 2D grid simulation, coordinate multiple entities with movement logic, and enforce collision-avoidance constraints.

    Coding & AlgorithmsTechnical ScreenSimulationGridCollision Detection
  • ShopifyEasySoftware Engineer
    Simulate rover movement on a grid

    This question evaluates incremental system design, agent state management on a bounded grid, and algorithmic complexity for processing movement commands in the Coding & Algorithms domain.

    Coding & AlgorithmsTechnical Screen
  • ShopifyMediumSoftware Engineer
    Terminal-Controlled Grid Rover Simulator

    Implement a warehouse rover simulation engine that processes sequential movement commands on a bounded 2D grid, handling coordinate translations, cardinal rotations, boundary limits, and multi-rover collision avoidance.

    Coding & AlgorithmsTechnical Screensimulationstate-machinearrays
  • ShopifyEasyData Engineer
    Write SQL for session analytics

    This problem tests your ability to clean event-based log data, perform time-series aggregation, and calculate session-level metrics using SQL window functions.

    Coding & AlgorithmsTechnical ScreenSQLWindow FunctionsData Cleaning
  • SiemensMediumMachine Learning Engineer
    Batch and Pad Variable-Length Vectors with Optional Final-Batch Dropping

    Implement an ordered data pipeline function that partitions variable-length numerical sequences into batches, applies batch-local right padding, handles empty vectors, and optionally discards incomplete final batches.

    Coding & AlgorithmsTechnical Screendata-pipelinesarraysmachine-learning
  • SierraHardSoftware Engineer
    Split Markdown Into Header-Aware Chunks

    This question evaluates string parsing, stateful text-processing, and algorithmic chunking skills, focusing on hierarchical header tracking and enforcing size constraints while preserving document order.

    Coding & AlgorithmsTechnical Screen
  • SigmacomputingMediumSoftware Engineer
    Build a Pivot Table Aggregator

    This question evaluates a candidate's ability to implement data aggregation and efficient lookup structures, focusing on grouping, associative aggregations, and maintaining intermediate state for derived metrics.

    Coding & AlgorithmsTechnical Screen
  • SigmacomputingMediumSoftware Engineer
    Evaluate a Formula AST with Variables

    This problem tests tree traversal techniques, recursive evaluation, and the implementation of short-circuit logic in expression trees containing variables.

    Coding & AlgorithmsOnsiteTreesRecursionAST
  • SigmacomputingEasySoftware Engineer
    Implement a basic pivot table with totals

    This question evaluates a candidate's ability to perform in-memory data aggregation, multi-dimensional grouping, handling missing combinations, and formatted text output for pivot tables including row/column totals.

    Coding & AlgorithmsTechnical Screen
  • SnapchatMediumSoftware Engineer
    Check if a binary tree is complete

    This problem tests your understanding of binary tree properties and your ability to perform a level-order traversal to verify structural completeness.

    Coding & AlgorithmsTechnical ScreenBinary TreeBFSData Structures
  • SnapchatMediumSoftware Engineer
    Compute islands in a binary grid

    This question evaluates a candidate's competency in modeling grids as graphs, detecting connected components, applying graph traversal algorithms (DFS/BFS) and disjoint-set (Union-Find) data structures, and analyzing algorithmic time and space complexity.

    Coding & AlgorithmsOnsite
  • SnapchatHardSoftware Engineer
    Compute longest increasing path in matrix

    This question evaluates algorithmic problem-solving skills in graph traversal and dynamic programming on matrices, measuring understanding of state representation and performance trade-offs in grid-based searches within the Coding & Algorithms domain.

    Coding & AlgorithmsOnsite
  • SnapchatHardSoftware Engineer
    Compute shortest path in a 2D grid

    This question evaluates understanding of graph traversal and pathfinding concepts, including modeling a 2D grid as a graph and reasoning about shortest-path computations and obstacle handling.

    Coding & AlgorithmsOnsite
  • SnapchatMediumSoftware Engineer
    Compute shortest recursive string encoding

    This question evaluates proficiency in string manipulation, pattern detection, recursion, and dynamic programming for efficient sequence compression in the Coding & Algorithms domain.

    Coding & AlgorithmsOnline Assessment
  • SnapchatMediumSoftware Engineer
    Compute sliding window median

    This question evaluates the ability to maintain a running median over a sliding window, testing competencies in data structures, order statistics, dynamic updates, and algorithmic efficiency within the Coding & Algorithms domain.

    Coding & AlgorithmsTechnical Screen
  • SnapchatMediumSoftware Engineer
    Count Grid Islands That Never Touch the Border

    Coding problem on a binary grid where 0 marks land and 1 marks water: count the islands, connected horizontally or vertically, that have no cell on the grid's border. It tests grid traversal, connected components and careful handling of islands that reach the edge through a single cell.

    Coding & AlgorithmsOnsite
  • SnapchatMediumSoftware Engineer
    Count islands with eight-direction adjacency

    This question evaluates a candidate's competency in graph traversal algorithms and data-structure trade-offs by counting connected components on a grid with eight-direction adjacency, focusing on BFS/DFS behavior and optional Union-Find approaches.

    Coding & AlgorithmsTechnical Screen
  • SnapchatHardSoftware Engineer
    Count ways to decode digit string

    This question evaluates a candidate's skill in dynamic programming and combinatorial reasoning about string partitioning, testing competency in counting valid decodings under constraint handling and edge-case analysis.

    Coding & AlgorithmsOnsite
  • SnapchatMediumMachine Learning Engineer
    Determine Whether Courses Can Be Completed

    This question evaluates understanding of graph modeling, directed cycle detection, and dependency resolution in the context of course prerequisites. It is commonly asked in the coding & algorithms domain because it reveals a candidate's algorithmic problem-solving ability and practical application of graph algorithms (expected O(V+E) time), testing practical implementation skills rather than only conceptual theory.

    Coding & AlgorithmsTechnical Screen
  • SnapchatMediumMachine Learning Engineer
    Determine and print expression to reach target

    This question evaluates skill in constructing and evaluating arithmetic expressions, handling numerical stability (including division-by-zero and floating-point tolerance), and reasoning about combinatorial permutations of numbers and operators.

    Coding & AlgorithmsOnsite
  • SnapchatMediumSoftware Engineer
    Determine blockage and parse HTML tokens

    This question evaluates computational geometry and graph connectivity for the circular-stones subproblem and parsing plus tree data-structure manipulation for the HTML-like token subproblem, measuring skills in modeling spatial overlap, graph traversal/union operations, hierarchical DOM construction, and dynamic node insertion/deletion.

    Coding & AlgorithmsOnsite