Question Bank
Every question, one list
Sandboxed coding rounds that run against a hidden test suite, and written questions graded against a rubric — side by side, because when you are drilling a topic you want both.
Topicimplementation (105)system-design (24)hld (20)trees (11)distributed-systems (10)arrays-hashing (9)concurrency (9)graphs (9)binary-search (8)consistency (8)dp-1d (8)linked-list (8)reliability (8)storage (8)
Clear filters8 questions · browse by bank instead
- Binary SearchWrite `search(nums, target)` returning the index of `target` in the ascending list, or `-1`. search([-1, 0, 3, 5, 9, 12], 9) -> 4 search([-1, 0, 3, 5, 9, 12], 2) -> -1 Everyone knows thieasyCoderpad#binary-search#implementation
- Find Minimum in Rotated Sorted ArrayWrite `find_min(nums)` returning the smallest value in an ascending array that has been rotated an unknown number of times. All values are distinct. find_min([3, 4, 5, 1, 2]) -> 1 find_min(mediumCoderpad#binary-search#implementation
- Koko Eating BananasWrite `min_eating_speed(piles, h)` returning the smallest integer speed `k` such that eating `k` bananas per hour finishes every pile within `h` hours. A pile takes `ceil(pile / k)` hours and a partiamediumCoderpad#binary-search#implementation
- Search a 2D MatrixWrite `search_matrix(matrix, target)` returning `True` if the value is present. Each row is sorted ascending, and the first value of a row is greater than the last value of the row above. search_mediumCoderpad#binary-search#implementation
- Search a rotated sorted arrayBinary search where one half is always still sorted. Finding which half is the entire question.mediumWrittenExplain to unlock#arrays#binary-search25 min
- Search in Rotated Sorted ArrayWrite `search_rotated(nums, target)` returning the index of the target in a rotated ascending array of distinct values, or `-1`. search_rotated([4, 5, 6, 7, 0, 1, 2], 0) -> 4 search_rotatedmediumCoderpad#binary-search#implementation
- Fewest machines to finish by a deadlineBinary search on the answer. Recognising that the question is monotonic is the whole insight.hardWrittenExplain to unlock#binary-search#greedy#optimisation30 min
- Median of Two Sorted ArraysWrite `find_median_sorted_arrays(a, b)` returning the median of the two ascending arrays combined, as a float. find_median_sorted_arrays([1, 3], [2]) -> 2.0 find_median_sorted_arrays([1,hardCoderpad#binary-search#implementation