This interview was for the SDE-2 position. The recruiter contacted me via LinkedIn.com
Question was asked that was based on array data structures and one java oops related question.
1. Hash map vs Concurrent hash map
2. Internal implementation of hash map
5. Another data structure related question which I couldn’t remember
1. Explain project in detail
5. Fizz buzz printing
Write an efficient program which takes an input argument say n. Start from number 1 to n (inclusive) and if number is multiple of 3 then print “Fizz”, if number is multiple of 5 then print “Buzz”, if number is multiple of both 3 and 5 then print “FizzBuzz”. The interviewer was looking for code with just two ‘IF’ statements.
1. Usage of synchronize keyword
2. Find graph type from given coordinates
Here we are given 4 types of graphs and we have an API which takes co-ordinates say (x1, y1) and (x2, y2). Everytime the API is invoked it would return the next coordinate in the plane. We have to find the type of graph with minimum number of API invocation.
Graph Types were Strictly increasing line, Strictly decreasing line, Increasing then Decreasing plane and Decreasing and Increasing plane.
3. Explain Singleton design pattern
4. Explain Factory design pattern
This was a non technical round with only behavioral questions.
1. Dynamic Dispatcher
2. Atomic keyword and volatile keyword
3. Externalizable interface
4. Having a method definition inside an interface but java version is 1.7 hence default shouldn’t be used.
5. Usage of try with resource block
6. Difference between upcasting and downcasting and when we should use them.
7. Creating thread without using thread class and runnable interface
8. Shutdown hook
9. 5 features in Java 1.8 and 1.9
10. Executor Pool vs Thread Join Pool
11. There are 3 threads running independently how to ensure 1st thread runs more frequently
12. Different ways of applying lock on hash map
13. How hash set is implemented internally and question if hash set uses hash map internally or hash map uses hash set internally.
Round-7 (Hiring Manager)
Given a 2D array with 5 Rows and 3 Columns and a number n. Print all combinations of the array elements upto n. Example;
Array elements are;
a b c
d e f
g h i
j k l
m n o
If n is 2 then output should be: ad ae af bd be bf cd ce cf
If n is 3 then output should be: adg adh adi aeg aeh aei afg afh afi bdg … (and so on)
- Amazon Interview Experience for SDE2 | 3+ years Experienced
- Microsoft Interview experience | Set 114 (2.5 Years Experienced for SDE2)
- Groupon Interview Experience | Set 4 (SDE2 for Experienced)
- Amazon Interview Experience for SDE2 (3 years exp)
- Walmart Interview Experience for SDE2 | Set 19 (3.8 years experience)
- OYO Interview Experience | Set 11 (For 2 years experienced)
- Oyo Interview Experience | 3.5 years Experienced for SDE-2
- Oyo Interview Experience | 3 years Experienced for SDE-2
- Amazon Interview Experience for SDE 2 (3 years Experienced)
- Microsoft Interview Experience (3 years Experienced)
- Oyo Rooms Interview Experience | SDE 2 (3 years Experienced )
- Oracle Interview Experience (2 Years Experienced)
- Amazon Interview Experience | SDE-1 (1-1.5 years experienced)
- Amazon Interview Experience(2 years Experienced)
- Nearbuy Interview Experience | Set 4 (2 Years Experienced)
- Apptio Interview Experience | SDE-1 for 2.3 years experienced
- Microsoft interview Experience | Set 48 (For 1.5 Years Experienced)
- Microsoft IDC interview Experience | Set 47 (For 1.7 Years Experienced)
- Intuit Interview Experience | Set 7 (For 3.5 Years Experienced)
- Microsoft Interview Experience (2-3 years Experienced)
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to firstname.lastname@example.org. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.