Watch others solve Arrays interview questions, see how they did, and learn from their mistakes.
Get step-by-step instructions on how to approach and solve common technical interview questions.
Given the head of a linked list, reverse the list and return the new head.
Given a string s, find the length of the longest substring without repeating characters.
Given a non-empty array of integers, return the k most frequent elements
Given n non-negative integers, find two lines that form a container that can hold the most amount of water.
Given an integer array and an integer k, return the kth smallest element in the array.
Given an unsorted array of integers and an integer k, find the number of subarrays whose sum equals k.
Given an array of integers, return an array of triplets such that i != j != k and nums[i] + nums[j] + nums[k] = 0.
Given an array of integers, transform the array in-place to a max heap.
Given an array of integers, return the indices of the two numbers that add up to a given target.
Given an input string `s`, reverse the order of the words without reversing the words themselves.
Given a two-dimensional binary matrix where 1 represents water and 0 represents land, mutate the matrix in place and return the matrix with the highest peak maximized.
Design and implement an efficient sampler that works in average O(1) time complexity.
Given an unsorted array of unique integers (size n + 1) and a first array identical to the second array but missing one integer (size n), find and output the missing integer.
Given `n` pairs of parentheses, write a function to generate all combinations of well-formed parentheses.
Given an integer array nums and an integer k, return true if it is possible to divide this array into k non-empty subsets whose sums are all equal.
Given a list of integers L and a number K, write a function that reorganizes L into three partitions: elements less than K, elements equal to K, and elements greater than K. No additional lists may be used.
Given a 2D matrix, where "1" represents land and "0" represents water, count how many islands are present.
Given a list of meetings, represented as tuples with a start and an end time, determine the minimum number of rooms required to schedule all the meetings.
Interview prep and job hunting are chaos and pain. We can help. Really.