Interview questions
Sde interview questions – page 4
112 questions. Tap “Show answer” to check yourself.
-
What inspires you to join Amazon? Why dream company ?
-
What is the meaning of memory leakage?
-
Write a program to show whether a graph is a tree or not using adjacency matrix
-
When can you say a graph to be a tree?
-
What are the differences between graph and tree?
-
What is the definition of tree ?
-
How to find kth- smallest element in BST? http://www.geeksforgeeks.org/find-k-th-smallest-element-in-bst-order-statistics-in-bst/
-
Describe ACID properties in detail
-
What happens on server side on receiving HTTP requests and how operating system interacts and then discussion related with threading, thread pool ,synchronization, hashing etc
-
What happens when we type amazon.com ?
-
Describe transaction process in detail if we want to transfer from one account to other. Also design scheme for it
-
reasons for leaving present company, ,
-
about my projects and contribution to present company
-
Why would you choose Amazon and not Flipkart if you have offers from both
-
How to know the time between someone writes Amazon.com and the page appears on his browser for a particular user. I impressed him by suggesting to use dummy request packets after the page is loaded completely sending the time J
-
There are n nuts and n bolts represented in two different arrays and a function is_fit(nut_i, bolt_j) which returns 0 if its perfectly fit, 1 if itÂ's a tight fit and -1 if its loose fit. I was asked to arrange them so that every nut fits perfectly with the bolt in the same position (there is one nut for every bolt that fits perfectly). I suggested O(nlogn) solution
-
Find the kth largest element in a BST. Well that was easy JWe discussed about projects and he asked reasons for leaving present company
-
Basically it was from snakes and ladders game. There is n x n matrix and you are at starting position. What is the no. of ways to reach n-square position if your next move will be dependent on number on dice? You have been given information about ladders (there are no snakes J )
-
Write an efficient program to count number tree structures that can be made using n number of nodes. Basically T(n)=summation (T(i) * T(n-i-1)). I used DP as there are a lot of sub-problems used again and again. O(n2)
-
Implementation of Least Recently Used Cache. I started with O(n) solution using queue and ended up with O(1) solution using heap and doubly linked list
-
There are billions and billions of stars and at any point of time you need to tell the closest million to earth. In what way I should take input for the stars and what all do I need to represent one. I used heap of a million size. Then he also asked about the different approach when I canÂ't use so much of physical memory for heap
-
There is a 12 km road and a contractor who is in-charge of repairing it. Contractor updates you about the work which is done in patches. Like "Road between 3.2 km to 7.9 km repaired ", "Road between 1.21 km to 3.2 km repaired". You have a manager who enquires about the longest continuous patch so far. It was a long discussion and I gave solution in O(nlogn) where n is the number of updates by the contractor