Question bank
4,310 interview questions, answered.
Reference answers, what the interviewer is really testing, how it is graded, and the follow-ups that come next.
Easy 190Medium 2,498Hard 982
Filters · onDifficulty, topic, company
164 questions
- 121Tree traversal, BFSCoding·
Amazon - 122TreesCoding·
Amazon, Infosys - 123Two pointerCoding·
Amazon - 124Ugly NumberEasyCoding·
Amazon - 125Wildcard matchingCoding·
Amazon - 126Course ScheduleMediumCoding·
Zoho - 127Given a list of items with different sizes, write an algorithm to pack these items into the minimum number of batches without exceeding the capacity of each batch.MediumCoding·
Amazon - 128Given the root of a binary tree, return the length of the diameter of the tree.MediumCoding·
Amazon, Google - 129Count items within compartments between specific indices of an array.MediumCoding·
Amazon - 130Find the first missing positive number in an array.HardCoding·
Amazon - 131Implement file searchMediumCoding·
Amazon - 132Implement a k-nearest neighbors algorithm.EasyCodingAI ML·
Amazon, Pinterest - 133Implement a phrase search in a list of documents.MediumCoding·
Amazon, Confluent - 134Implement LRU Cache.HardCoding·
Accenture, Adobe - 135Find the maximum product of any two integers in an array.MediumCoding·
Amazon - 136Find the maximum possible stability of any subset of servers. Return the result modulo 10^9+7. E.g. Consider set of servers where reliability = [1, 2, 2], availability = [1, 1, 3].MediumCoding·
Amazon - 137Most Common WordsEasyCoding·
Amazon - 138Move all zeros to the end of an array.EasyCoding·
Adobe, Amazon - 139Given a string of parentheses types and an array of their efficiency ratings, write a function to find the most efficient valid parentheses sequence that can be formed. Return its total efficiency score.HardCoding·
Amazon - 140Session Data Analysis.HardCodingTechnical·
Amazon - 141How do you split a machine learning dataset for training, evaluation, and testing?MediumCoding·
Amazon - 142Write a query to find all dates where the stadium had three or more consecutive days with attendance of 100 or more people.HardCodingData·
Amazon - 143Write a query to find the top 3 unique salaries in each department and list all employees who have those salaries.MediumCodingData·
Amazon - 144Get the top API users based on transaction logs.MediumCoding·
Amazon