# Amazon WoW Internship Interview Experience 2022

• Difficulty Level : Medium
• Last Updated : 04 Mar, 2022

I had 2 technical rounds on Amazon Chime. For all DSA questions, I asked about given data types, corner cases, and return type(s).

Technical Round 1

The interviewer introduced himself, and asked me to do the same, he told me to consider this interview as a discussion session.

• The interviewer asked me about my favorite data structure, my answer was Linked list and tree, maybe, therefore, my first question was:
• Given a binary tree root and a linked list with the head as the first node. Return True if all the elements in the linked list starting from the head correspond to some downward path connected in the binary tree otherwise return False. (also known as ” Linked List in Binary Tree”)
• I told me brute force solution and time-space complexities. He asked me to write the code, I told him that I can improve the approach and told him an improved approach. During the whole time, the moment I was picking the path towards the correct approach interviewer was acknowledging me by saying “yes you are going in the right direction”. He was quite impressed with my code and approach.
• Next greater element
• https://www.geeksforgeeks.org/next-greater-element/
• I told him brute force and then improved his approach.
• He asked me to write pseudo code for this question.

The next day received mail for the next round, round was scheduled for the same day.

Technical Round 2

The interviewer introduced herself and asked me to do the same.

• Lowest Common Ancestor: https://www.geeksforgeeks.org/lowest-common-ancestor-binary-tree-set-1/
• First I explained the brute force solution, she asked for time and space complexity, then I told her the improved solution and wrote the code and time-space complexities.
• Given an n x n grid containing only values 0 and 1, where 0 represents water and 1 represents land, find a water cell such that its distance to the nearest land cell is maximized, and return the distance. (also known as ” As Far from Land as Possible”)
• I was able to give a brute force solution ( BFS calls for each 0 of the grid)
• She was giving me hints to improve it, but I couldn’t.
• In the end, she asked me to write the code for the approach (brute one) and time-space complexities.

Received positive mail after 8 days.

Verdict: Selected

My Personal Notes arrow_drop_up