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

205 questions

  1. 73Find the minimum characters to insert to make a string a palindrome.MediumCoding· Uber
  2. 74Given a large n-ary tree where the root node can pass information to one child per iteration, and in subsequent iterations, nodes can pass information to one child while the root continues with others, find the minimum number of iterations to reach all nodes.MediumCoding· Google
  3. 75Given two strings (Word 1 and Word 2) and a list of valid words from a dictionary, return the minimum number of operations required to convert Word 1 to Word 2.HardCoding· Airbnb
  4. 76Find the minimum window substring.MediumCoding· Airbnb, Dropbox
  5. 77Most Common WordsEasyCoding· Amazon
  6. 78Move all zeros to the end of an array.EasyCoding· Adobe, Amazon
  7. 79Partition an array into two sub-arrays with equal sum.MediumCoding· Apple, LinkedIn
  8. 80Print all words from a dictionary that can be found on a given Boggle board.MediumCoding· Microsoft
  9. 81Given a matrix with a rat, bread, cat, and obstacles, find a path from the rat to the bread that maximizes the minimum distance from cat.HardCoding· Google
  10. 82Write functions to serialize and deserialize a list of strings.MediumCoding· Google, Nvidia
  11. 83Sort an array containing only 0s, 1s, and 2s.MediumCodingTechnical· LinkedIn
  12. 84Sort a binary array in linear time.EasyCoding· Accenture, Apple
  13. 85How do you split a machine learning dataset for training, evaluation, and testing?MediumCoding· Amazon
  14. 86Squares of sorted arrayMediumCoding· Meta, PayPal
  15. 87Given a sorted array of integers (which may include negatives), return the squares of the numbers in sorted order. As a follow-up, find the k-th smallest squared value.MediumCoding· Uber
  16. 88How would you store a list of numbers as a single number?MediumCodingTechnical· Atlassian, Microsoft
  17. 89Given an integer array nums and an integer k, return true if nums has a subarray of at least two elements whose sum is a multiple of k.HardCoding· Adobe, Apple
  18. 90Sudoku SolverHardCoding· Adobe, Apple
  19. 91Get the top API users based on transaction logs.MediumCoding· Amazon
  20. 92Print the top view of nodes in a binary tree.MediumCoding· Amazon
  21. 93Transform a flat array of objects into a nested list.MediumCoding· New York Times
  22. 94Calculate the trapped rainwater between bars in a given array.HardCoding· Adobe, Amazon
  23. 95Given a string s, return true if the s can be a palindrome after deleting at most one character from it.MediumCoding· Meta
  24. 96Vertical Traversal of a Binary TreeMediumCoding· Meta, Oracle