Interview questions
Find a company or topic. Read the sources, then practice.
Loading the question library…
Find a company or topic. Read the sources, then practice.
Loading the question library…
Showing 1,551–1,575
Given start positions and speeds of cars heading to a target where cars cannot pass but can catch up, count how many groups ("fleets") arrive…
General practice
For each car in increasing position order, determine the time it first collides with the next car ahead, accounting for the fact that cars can…
General practice
Given pairs of numbers on n flippable cards, find the smallest integer that can be made to face down on some card while never appearing…
General practice
Determine whether the mouse can force a win in an alternating perfect-information game on a grid with walls and food, where each turn the mouse…
General practice
Given length, width, height, and mass, determine if the box is "Bulky" (any dimension ≥ 10^4 or volume ≥ 10^9) and/or "Heavy" (mass ≥ 100)…
General practice
Parse the start and end column letters and row numbers from a string like "K1:L2" and generate all cell identifiers within that inclusive rectangular range…
General practice
Given an m×n zero matrix and a list of indices where each (r,c) increments all cells in row r and column c, determine how many…
General practice
Given a rooted company hierarchy with the CEO at the top, answer queries about subordinate relationships (e.g., count direct/indirect subordinates, test if one employee is…
General practice
Determine whether Alice has a winning strategy in a two-player game where players alternately erase one number and the player who makes the XOR of…
General practice
Given poured cups into the top of a triangular glass tower where each glass holds 1 cup and any excess splits equally to the two…
General practice
Given a students DataFrame, convert the grade column from float to integer and return the updated table preserving all other columns.
General practice
Given two lowercase strings, find the minimum single-character edits to either make every letter in a strictly less than every letter in b (or vice…
General practice
Given an ordered table where some column values are NULL, replace each NULL with the most recent preceding non-NULL value (usually within the same group)…
General practice
Determine whether arr can be formed by concatenating the arrays in pieces (you may reorder pieces but cannot change the order within any piece). With…
General practice
Given a numeric string, determine whether the sum of digits at even indices equals the sum at odd indices and return true if they match…
General practice
Given a string where each lowercase letter that appears does so exactly twice and a 26-length array mapping 'a'..'z' to required counts, verify that for…
General practice
Given a positive integer n, compute the sum and the product of its decimal digits, add those two values, and return whether n is divisible…
General practice
Given a set of equations and relations between variables, determine whether all constraints can be satisfied simultaneously by detecting any contradictory cycles in the implied…
General practice
Given a sorted array and a target value, determine whether the target appears strictly more than half the array's length (is a majority element). Leverage…
General practice
Given a parentheses string where some characters are fixed and others can be flipped, determine whether you can change the unlocked positions to form a…
General practice
Given two equal-length lowercase strings, determine whether some permutation of one can have every character >= the corresponding character of some permutation of the other…
General practice