1) Given list of numbers which are sorted and have duplicates . find first occurrence of a number such that
A[i] = i . We had a discussion on this . HE asked me to write unit test cases.
code worked in case of no duplicates, duplicates which are smaller or greater than required element . His test case was like -100, -10, -20, 3, 3, 3, 3, 3, 3, 9 failed on my code
2) Again gave array searching question. Given an array of elements like follows
10, -20, 20, -20, 20, 30, 30, -30, -40, -50, -60, 70, 90 where this array is not sorted . If you take absolute of all the elements this array will appear sorted. Find the first occurrence of 20 in this array.
3) Implement queue using stacks. gave this one.
4) linked list with a cycle somewhere . find the point where cycle exists and length of the cycle.
Asked me to write production quality code. gave this one correct I feel.
Asked me language which I like the best. I said c++
Sort of c++ round as I have c++ exp. asked me to
1) virtual functions
2) const discussion. meaning of const int * p and int * const p etc
but one question was interesting in this discussion
int *const p = (int *)malloc (sizeof(int)*10) ;
he said will you ever be able to deallocate this memory since this is const?
3) shared_ptr question and how will you use them in case you have templates
3.1) discussion on template specialization in the above case.
1) Design a pen
the discussion was long . I didn’t understand what he was trying to get from me. I did make classes but he was not convinced.
Hr said will contact me.
- Adobe Interview Experience (2 years experienced)
- Adobe Interview Experience | Set 38 (4.6 Years Experienced)
- Adobe Interview Experience | Set 37 (3.5 Years Experienced)
- Adobe Interview Experience | Set 39 (1.5 Years Experienced)
- OYO Interview Experience | Set 11 (For 2 years experienced)
- Adobe Interview Experience | Set 45 (For 2.5Years Experienced)
- Adobe Interview Experience | Set 23 (1 Year Experienced)
- Paytm Interview Experience | Set 11 (For 2 Years Experienced)
- Amazon Interview Experience | Set 340 (3.5 years experienced for SDE 1)
- BirlaSoft Interview Experience | 2.2 years Experienced
- Paytm Interview Experience | Set 18 (For 2 Years Experienced)
- Microsoft Interview Experience | Set 154 (For 1.5 Years Experienced)
- Microsoft Interview Experience | Set 111 (For 1.5 Years Experienced)
- Cadence Interview Experience | Set 3 (For 6 Years Experienced)
- Microsoft Interview Experience | Set 112 (For 4.5 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 email@example.com. 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.