Skip to content
Related Articles

Related Articles

Improve Article
Save Article
Like Article

Amazon Interview Experience | Set 382 (On-Campus for Full Time)

  • Difficulty Level : Hard
  • Last Updated : 11 Jul, 2019

The Selection process started with an Online Coding round.

20 MCQ and 2 Coding Questions:
MCQs were from OOPs, OS, DBMS, Networking etc.

Hey geek! It's time to become a success story instead of reading them. Check out our most renowned DSA Self Paced Course, now at a student-friendly price and become industry ready. And if you are looking for a more complete interview preparation resource, check out Complete Interview Preparation Course that will prepare you for the SDE role of your dreams!

Feeling prepared enough for your interview? Test your skills with our Test Series that will help you prepare for top companies like Amazon, Microsoft, TCS, Wipro, Google and many more!

Coding Questions:

  1. Rotate the given Matrix by a factor k. Input is given as two integers n,m (row and column of the matrix). Followed by n lines with m space separated integers as all the elements of the matrix. Last line has an integer k.
    GeeksforGeeks Link
    3 3
    1 2 3
    4 5 6
    7 8 9
    7 4 1
    8 5 2
    9 6 3
  2. Given a string. Find all the palindromic partitions of the string. (Number of way the string can be partitioned so that all the partitions are palindrome)
    GeeksforGeeks Link
    Input: str = "NITIN"
    N I T I N
    N ITI N

Face2Face (Interview)

Round 1:

He asked coding questions straight away –

  1. Add two numbers without using +,- operator, recursion or loop.
    Try to think in terms of half adder.
    GeeksforGeeks Link
  2. Postfix to prefix without using recursion.
    GeeksforGeeks Link
  3. Given an array of numbers. What is the largest no possible by concatenating all the numbers together.
    GeeksforGeeks Link
    21 30 1 9 98
  4. Write the heapify code.

Round 2:

  1. Level order traversal of a tree. Further he asked to optimise the code.
    GeeksforGeeks Link
  2. Given a matrix. ‘0’ means empty room, ‘1’ means door, ‘-1’ means a wall. For every cell as an empty room find the distance to the nearest door (One cannot go through a wall).
    GeeksforGeeks Link
    5 5
    0  0  1 -1  1
    0 -1  0  0 -1
    0  0 -1  0 -1
    1 -1  1  0  0
    0  0  0  0  0
    2  1  0 -1  0
    2 -1  1  2 -1
    1  2 -1  2 -1
    0 -1  0  1  2
    1  2  1  2  3

    The door would be replaced with 0 as the distance to the nearest door would be 0.
    I started by a backtracking solution. But the guy didn’t know what it was. I gave many more solutions and concluded with an O(N) bfs solution.

Guys answer straight. Do not answer very complex algorithms, even though they are correct. Try to provide as brute-force solution as possible.

If you like GeeksforGeeks and would like to contribute, you can also write an article using or mail your article to See your article appearing on the GeeksforGeeks main page and help other Geeks.

Please write comments if you find anything incorrect, or you want to share more information about the topic discussed above.

My Personal Notes arrow_drop_up
Recommended Articles
Page :

Start Your Coding Journey Now!