Amazon | Onsite | New Grad | USA
Anonymous User
977

LC mediums and easy. USA. 3 interviews. Did not get offer, interviewers asked for indepth knowledge of algorithms, time in big O notation for all functions and parts of functions. Multiple interviewers had questions which they only mentioned with 5-10 minutes to go and expected an indepth explanation for them, while the other question took up the bulk of the time.

  1. Problem similar to LRU Cache, just extra wording - easy part. https://leetcode.com/problems/lru-cache/
  2. Assuming you do not have access to int() and char() functions, convert a string of characters to integers. If encountering a nondigit character, ignore the input. Assume you have access to ord(). Example input to ouput is "00124" -> 124, "67e9" -> 67, "b" -> 0, "-1245" -> -1245.
  3. Build an optimization algorithm to minimize subscription cost for a user. Assume an ordered list with values between 1 and 365. Prices = [3,8,22] where Prices[0] = daily, Prices[1] = weekly, Prices[2] = Monthly. Example list: [1,3,4,5,7,8,20]. Output = 14.
  4. Search words, find k top search terms from data stream. For instance: Search:"Apple" Top: ["Apple"],Search: "Banana" Top ["Apple","Banana"], Search: "Banana", Top: "Banana"
  5. Check if a BST is valid.
Comments (2)