READ. UNDERSTAND. PRACTICE.
Coding questions
Explore algorithm tutorials, coding and system design questions, interview experiences, and computer science study guides.
1,899 resources · Page 73 of 80
Coding questions · Microsoft
Sort Three Categories In Place
This question evaluates proficiency in in-place array manipulation, constant-space algorithms, and linear-time partitioning techniques. Commonly asked in Coding & Algorithms interviews to assess algorithmic efficiency, pointer/index management, and reasoning about invariants, it focuses on practical application of algorithmic concepts rather than purely theoretical understanding.
Coding questions · Jane Street
Sort trade executions into a canonical order
This question evaluates a candidate's ability to enforce deterministic ordering and data normalization of time-series trade execution records, testing competencies in multi-key sorting, tie-breaking logic, and performance with large inputs.
Coding questions · Capital One
Sorted Sums of Absolute Differences Over All Cyclic Shifts of an Array
Given two integer arrays of equal length, compute the sum of absolute differences between the second array and every cyclic rotation of the first, then return all of these sums in non-descending order. It tests rotation index arithmetic, accumulation over every shift, and exact output ordering.
Coding questions · Carvana
Spell Out a Nonnegative Integer
This question evaluates a candidate's ability to decompose integers and implement precise string-formatting logic, including mapping numeric values to their English word equivalents and managing scale units and boundary conditions.
Coding questions · American
Spread Nine Stones Across a Three-by-Three Grid with Minimum Moves
Find the fewest orthogonal stone moves required to leave exactly one stone in every cell of a three-by-three grid.
Coding questions
Spreadsheet Formulas, Dependencies, and Circular References
Implement spreadsheet formulas with dependency updates, repeated references, unset cells, and cycle detection that recovers after formulas change.
Coding questions · Ramp
Spreadsheet String Concatenation with Dependent Cells
Build a fixed-grid string spreadsheet with concatenation formulas, dependency updates, repeated references, and read-time circular-reference errors.
Coding questions · Waymo
SQL: Average Ride Rating in Users' First and Third Active Months by City
Write a PostgreSQL query that compares average ride ratings in each user's first and third active months, grouped by city and averaged over individual rides. Tests ranking distinct active months per user, window functions, NULL ratings and weighting.
Coding questions · Waymo
SQL: Count Users With Zero or One Rides per City
Write a PostgreSQL query that counts, per city, the users who have taken zero or one ride in total, including users who never rode. Tests outer joins or subqueries that preserve zero counts, grouping by city, and filtering on aggregated totals.
Coding questions · LinkedIn
[SQL] Job Ad Metrics with Applicant Filter
This question evaluates proficiency in SQL data manipulation and deduplication, focusing on aggregations, distinct counts, and conditional filtering of event records (views vs applies).
Coding questions · Waymo
SQL: Monthly Ride Totals and Average Ratings, Newest Month First
Write a PostgreSQL query that reports, for each calendar month, the total number of rides and the average rating rounded to two decimals, newest month first. Tests month bucketing, counting unrated rides while averaging only rated ones, and ordering.
Coding questions · Waymo
SQL: Top 5 Vehicle Models by Miles per kWh Under a Maintenance Cost Cap
Write a PostgreSQL query returning the top 5 vehicle models by miles per kWh, limited to models with total maintenance cost under 5000 and safe when energy is 0 or NULL. Tests aggregating two child tables without join fan-out and NULL-safe division.
Coding questions · Waymo
SQL: Users With No Rides in the Most Recent 7-Day Window, Including Non-Riders
Write a PostgreSQL query that lists users with no rides in the most recent 7-day window, including users who never rode. Tests anchoring a date window to the data, inclusive boundaries, and anti-join logic that keeps users without matching rides.
Coding questions · Amazon
Stack Whose Pop Removes the Most Frequent Value, Ties Broken by Recency
Phone screen coding problem: process push and pop operations on a stack in which every pop removes the value that currently occurs most often, breaking ties by the tied value closest to the top. It tests designing a data structure that tracks frequency and recency together efficiently.
Coding questions · Stripe
Subtract Blocked Periods from Allowed Deployment Windows
Compute available deployment windows by merging allowed and blocked half-open intervals, subtracting overlaps, and returning maximal sorted nonempty ranges.
Coding questions · Agoda
Sum Employee Working Time from Ordered Check-In and Check-Out Events
Pair ordered employee attendance events and total working seconds, including multiple shifts and intervals crossing midnight.
Coding questions · Capital One
Sum of Distinct Values on the Borders of All Maximum-Sum Square Frames
Among all square frames of a given size inside an integer matrix, find those with the largest border sum, then add up the distinct values that appear on the borders of every such frame. Tests careful border enumeration that excludes interior cells, tie handling across several frames, and de-duplication by value.
Coding questions · Abridge
Sum of Integers Up to n Divisible by 3, 5, or 7
From an Abridge online assessment: given a positive integer n, return the sum of all integers from 1 to n that are divisible by 3, 5 or 7, adding numbers such as 15 or 21 only once. It tests precise handling of overlapping divisibility conditions and inclusive range boundaries.
Coding questions · Meta
Sum the Values of a Binary Search Tree That Fall Within an Inclusive Range
Given a binary search tree with distinct values in level-order form, return the sum of all node values that fall within an inclusive lower and upper bound, or zero when none do. It tests binary search tree traversal on trees of up to 20,000 nodes.
Coding questions · Moloco
Support Dynamic Range Sums
This question evaluates knowledge of data structures and algorithmic techniques for range queries and dynamic updates, along with complexity analysis for time and space.
Coding questions · Amplitude
Swap kth-from-end node with head
This question evaluates a candidate's understanding of singly linked list pointer manipulation, in-place node swapping with O(1) extra memory, and handling of edge cases such as when the k-th node from the end is the head.
Coding questions · Databricks
Tic-Tac-Toe Against a Deterministic Automatic Opponent
Build an automated Tic-Tac-Toe opponent with perfect-play minimax, deterministic move ties, board events, invalid attempts, and terminal-state handling.
Coding questions · Databricks
Tic-Tac-Toe with Automatic Turns and Board Snapshots
Implement two-player Tic-Tac-Toe with automatic turn changes, board snapshots, rejected moves, winning lines, and full-board draws.
Coding questions · TikTok
Tiktok DS Interview Questions
This question evaluates proficiency in SQL-based time-series aggregation, joins between streaming and viewing tables, conditional and null-aware aggregations, string and case-insensitive category filtering, and basic analytical functions used in data science workflows.