Here by share my rejection summary.

Im from ECE background and have bare minimum basics in the computer science fundamentals.

I have taken the decision to look for a change after completing 5 years and started giving interviews from 2016 jan.

Till date i dont have **success** .

1st interview with **JP morgan** .

round 1.

Question on operator overloading and basics of c++. After that he asked me about binary search tree.

You insert elements in BST tree in increasing order and tree is skewed, tell me the complexity of the element you search for. Said O(N).(its was O(height) of the tree, tree is skwed sthough it is O(N) have to tell O(height))

He asked me what i can do to make log(N) - no answer (balance the tree, AVL tree).

```
HR asked me to leave after round 1.
```

2nd Interview with **Make my Trip**

round 1.

```
1. Convert Binary Search Tree to Greater Sum Binary Search Tree.
2. Given an infinite number line series, -Infinity ... -3 -2 -1 0 1 2 3 .... +Infinity,
you are on number 0. You can jump 1 step to right(1) or left (-1)
if you move to 1, now you can make 2 jumps to right(3) or left (-1)
if you move to -1, now you can make 2 jumps to right(-3) or left (1)
from these numbers again you increase the steps and move right or left accordingly. He will give you a number, lets say 10.
you have to find out number of steps required to reach number 10. Simple BFS problem.
2 problems i was not able to solve. I left this time before HR informed.
```

3rd Interview with Oracle

Telephonic

```
1. Flatten the linked list. Linked list has next and child pointer.[https://www.geeksforgeeks.org/flatten-a-multi-level-linked-list-set-2-depth-wise/](http://)
2. Height of Binary Tree.
1st one i was able to solve, partially. 2nd one completely. But they have rejected.
```

4th **TAS Solutions** .

round 1.

```
1. Asked me to implement Map Reduce algorithm.
2. Questions about process, threads, communications between threads, mutex, etc.
3. Linked list, graph questions.
Implemented 1, 2nd one couldnt tell properly.
```

After these interview i understood, have to be aware of algorithms and datastructures, before that have to master **recursion** , without which i cant fight.

**Recurrsion is basics for everything** . Take Trees, DFS, solving linkedlist problems, backtracking, Dynamic Programming(which is smart recursion, i call it like this. If you dont agree, i dont care. Still its a smart recursion).

finding x power y, factorial, GCD can help you.

Now i have learnt few basics of binary tree(traversals), DFS, BFS, basics of Linkedlist.

5th **Teradata**

Telephonic

```
1. DO you know preorder traversal. Yes, explained the recursion code.
Fantastic, now please do it without recursion. :(
rejected ... Hmmmm
```

Then i worked on Trees, BST, AVL Tree, DFS, BFS, Graphs, Dijstra, Minimum Spanning Tree, Topological sort, Backtracking(rat in a maze, with visited matrix, without visited matrix, number of ways from starting and ending of matrix, suduko, nqueens).

After these 5 interviews i understood, we should know these classical problems.

Not one solution, should know multiples solutions and their complexities.

**Understand these complexities, else interviews will make your life complex.**

6th **Cisco**

round 1

```
2. 1. On my project
2. find a pivot point where, left and right half of array has equal sum.
[Rejected as i couldnt answer concepts of c++, move semantics, belive me i work on c++ but i dont know what is move]
HR asked to "move" out of company.
```

7th **Flipkart**

round 1.

```
some online coding round, thanks to hackerrank, it concluded that im not fit for flipkart in 1 hour. Though i solved 1 question out of 2, they are looking for someone who solved both.
I understood that i haven't mastered the art of problem solving, i started doing more problems in geeksforgeeks (i dont know about leetcode at that time, leetcode is more organized than gfg).
```

By this point i have solve many problems on trees, graphs and take me for granted, ill write AVL tree if you wake me from my sleep. **I literally mugged up.**

Now i entered critcial phase of my life. I have decided to move to another company at any cost as i assume that i know DataStructres and Problem solving.

I know trees (binary, BST, AVL, B+trees, segment trees, heaps), graphs, tries, hashmap, linkedlist, still i had now success, as interviewers has **"DESIGN"ed** something new to teach me.

I forgot that i have **gained experience** while learning these, now they started asking me OOD and System Design.

I didnt realize this because i used to exit from process in 1st round, now that i have started clearing 2 problem solving rounds, **i realize i have to learn OOD and System Design as well.**

Many dont try to understand or try to learn the internals of the project we do. Because most of the code is already written(atleast in my case) and we just need to fix issues rather than developing features. I tried to fix the issues without knowing the design.

Let me share that night mare as well.

8th **Microsoft**

```
no problem solving as im 10 years in to industry :(
```

round 1.

```
1. Design a complex number ans polynomial class.
2. Design Vector class.
```

round 2.

```
1. You have a outlook mail client, every day when you open your mail client show me list of email ids which you havent contacted or they havent contacted you for past 90 days. Dont think much, its simple LRU cache variation, i solved this in 1 hour. He was expecting me to solve in 15 min i guess.
```

Please have lunch and take a leave after this.

9th **Adobe**

round 1

```
1. AVL tree question, I answered. I literally said to interviewer, i can write the code, please allow me to write.
2. on C++ move, decoupling mechanisms etc.
```

round 2.

```
1. Question is based on heap. Top K elements from array. Written flaw less code
2. Reverse Linkedlist.
```

round 3.

```
1. Design online game for two players.
did designed, but not so great. I staright away jumped in to how to write the code(LLD), didnt do HLD. He gave feeback saying poor in designing.
```

round 4.

```
1. Director want to check, if im really poor in designing.
Asked me to design a view system, where you open multiple views of same window and you try to modify the file name in any one of the view, changes should be reflected to other views as well.
Simple model-view-controller, I couldnt spell out these model, view, controller, technical terms, said ill have observer with memory and try to update etc... was not convinced,
```

**so didnt get the offer First time i went till the final round.**

10th **Uber**

round 1

```
1. Find maximum continous elements length in the random array. (use hashmap to solve this). Did well.
```

round 2

```
2. 1. Design a system of my choice, where if i need to add new code, new module, instead of if-else-if-else blocks i have to design my classes in such a way that, very minimal changes has to be done for the classes.
basically, classes should be open for extension and closed for modification ( i dont know this at that time)
I have to use stratergy pattern to dynamically select algorithms on the fly. I knew nothing. I failed here.
```

round 3.

```
1. Manager asked Leadership principle questions (as he was ex amazon guy) and asked me to design UBER.Which i fairly did with the help of quadtree. but round 2 have given very bad feedback so have to go back to my home after this.
```

11th **Amazon - canada.**

round 1. online coding - cleared 2 questions.

round 2. video call - given a list of elements where you have all the elements repeated twice and only 1 element is unique. (exor all the elements, first answer) follow up question, what if you have 1 1 1 2 2 2 3 -> now find 3 from this array. Single number ii question in the leetcode. solved this as well.

inivted for onsite round, but didnt go because of personal issue and asked them to conduct virtual interview.

round 3. LP, Design a datastructure where you insert, delete and get random in O(1)

round 4. LP, Design a analytics page to know about user profile data globally.

round 5. LP, You have connected users in a graph, you have to design algorithm where you identify clusters where people have voted for candidate A and certain people have voted for candidate B.

I have given a solution like dual BFS traversal from both the ends.

round 6. LP, Valid parenthesis question.

I have solve this question using stacks, but he asked me to solve using hashmap(which i did later.This reduces the code to check for parenthesis).

Result - Rejected

**I did bad in design, i have recorded the interview to analyze what i was talking. I did very poorly in the design round.**

12th **Adobe - Again they called me**

round 1.

```
Explain singleton and write singleton class -> add threadsafety to singleton.
```

round 2.

```
Design a grabage collector - explained mark and sweep algorithm.
```

round 3.

```
some puzzle on locked latches.
Design Timer
```

round 4. This was kickass round from problem solving he went to designing.

```
1. print tree in a zig-zag way.
2. "My Name is Khan" convert this to "Khan is Name My" without using string library.
3. Design Logger Library - use multithreading designing as well as chain of responsibility pattern where he was impressed.
4. Multithreading
```

**I expected this time i would get offer. They rejected again. I really have no clue where i went wrong in this interview. Only mistake i did was i didnt solve puzzle.**

13th **Microsoft - failed again**

round 1.

```
1. Reverse K Nodes in linked list. - written bug less code.
2. Print even odd numbers in multithreading environment. - yes i have written this as well.
```

round 2.

```
1. BST problem. You are given a BST tree and a node, and for a given K, you have to find K nodes whose absolute difference with given node is minimum. Used max heap and solved.
2. Design Ticket Vending Machine - failed again.
```

round 3.

```
1. Design Tic Tac Toe game - pitfall.
2. Given a string if it has two adjacent letters, try to swap them and make sure string doesnt have adjacent letters.
"AAABBB" -> "ABABAB" -> solved with bruteforce approach, have to use heaps (didnt strike this time).
```

**Feedback- didnt ask enough question in the design round and straightly jumped in to the solution.**

**You are terminated from the process **

Till today i didnt find any success which im looking since 2016 and 2020 is nearby.

For one who didnt have fundamentals of DataStructres and algorithms,

who never designed any application

who never worked on server or database

who never worked with clients

who has **zero luck**

**Have to struggle.**

**3 Categories i have divided.**

**1. Problem Solving**

One should practise problem solving, where leetcode is better place, which is organized in to categories.

One has to solve daily one problem, easy problems are damn good to start. Build the inertia.

Know different solutions for one problem. Solve bruteforce and think other options as well. Can we do with recursion, if we cant do with recursion can we use stacks, etc.

Always prepare for follow up questions, you get a follow up question if you solve the first problem instantly.

follow up question will always be asked for better complexity or for less code or to trouble you.

prepare multithreading- concurrent programming. You have to write the code and know the concepts. Better to solve **concurrency problems on leetcode with different solutions.**

**2. OOD design.**

one should know how to design interfaces, First learn **SOLID principles** ,https://www.youtube.com/watch?v=yxf2spbpTSw whey they are required.

Understand design patterns for which **dont learn them with duck or rectangle examples. this wont work.**

check for practical applications of design pattern and try to apply them while design you own applications.

Dont learn stratergy pattern with duck examples.

Where can you apply stratergy pattern ?

ok, user initiated payment for product purchase in the cart.

he chose paymethod as cash instead of debit card, google pay. So we assign cash as payment mode in runtime.

we chose different payment method(different algorithm in the runtime), here we can apply stratergy design pattern.

for example - **design time, stopwatch, product vending machine with design patterns.

**

**3. System design.**

i still dont know how to crack this though i watched techdummies or grokking the system design educative.io course., im not able to perform well in this round.

one should have stratergic plan to crack the interview i guess !!!

one problem i have is i jump in to coding (which i feel im comfortable) when system design questions are asked.

i dont ask questions

get clarity on requirements.

One who can overcome the weakness only can win this game.

I have all the issues(1 and 6) mentioned by this guy in quora https://qr.ae/TcmPiK , Do read this post and evaluate your mistakes.

Thanks for reading my messed up story !!!

Happy Learning.