Amazon Interview Experience | Set 320 (Off-Campus)

Recently i attended interview at amazon hyderabad for SDE-1.

Written round Two questions

  1. Find the unique character from two strings
    http://stackoverflow.com/questions/29794233/how-to-print-unique-alphabet-from-two-strings-using-java
  2. Parenthesis match problem
    https://www.geeksforgeeks.org/check-for-balanced-parentheses-in-an-expression/

Face to Face

  1. Two colors are given(yellow, blue), we have to color such that no consecutive blue color is painted
    Given the arrival and departure time of various trains in a station. Calculate the minimum number of platforms required such that no train has to wait for another train to vacate the platform.
    The question basically means calculate the maximum number of trains that would be present in the platform at any given time.
    Answer
    sort the arrival time and sort the departure time, keep a count initialized to 0. compare the first element of the arrival time with the first of departure, increase the value of count if the value at current Index at arrival is less than the value index at departure and increment the arrival index, and vice versa. Keep the maximum count that you see.

Second face to face

  1. Implement stack using queue
    https://www.geeksforgeeks.org/implement-a-stack-using-single-queue/
  2. Reverse linked list form n occurence ————–not so good
    https://www.geeksforgeeks.org/reverse-a-list-in-groups-of-given-size/ 1->2->3->4->5->6->7->8
    if k=3;
    3->2->1->6->5->4

Third face to face



  1. Design elevator in OO perspective.
  2. How class is loading in JVM:- Discussed about eden, perm space. using graph and BSF & DFS.
  3. Clone the binary tree.

I didn’t got call after that.

If you like GeeksforGeeks and would like to contribute, you can also write an article and mail your article to contribute@geeksforgeeks.org. 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

Write your Interview Experience or mail it to contribute@geeksforgeeks.org




 
Practice Tags :
Article Tags :
Please write to us at contribute@geeksforgeeks.org to report any issue with the above content.

Recommended Posts:



2.1 Average Difficulty : 2.1/5.0
Based on 9 vote(s)