Tip 1: Code More
Tip 2: Study Data Structures
Tip 3: Be Confident
Tip 1: Mention only what you are confident about
Tip 2: Mention tools & technologies used in the project as well
25 mcqs and 2 coding questions
(It was a part of Amazewow process via Amazewit https://www.amazewit.in/)
Timing- any time between 22-24 may 2020
Webcam was on.
I first thought of the brute force approach.
Then tried to solve for LIS which I had already solved once.
Then implemented the approach of DP for LDS.
It held at morning 10 AM.
The interviewer was very friendly.
I was asked to solve 2 coding questions and was continuously provided with hints by the interviewer.
Question was on Array and Trees.
Input: 56 54 63 74 69
Output: 3
I first thought of the brute force approach using 2 for loops.
Then I thought of using a Stack.
Then by using a heap.
Finally, I was able to code it using 2 additional arrays (max and min).
it took O(n) time complexity and O(n2) space complexity.
Edge Case: For the first student, there is no lighter student in front but we only have to consider heavy students for him.
Simil...
First I wrote the post order traversal of input,
Then by simply doing post-order traversal and performing swapping in between.
Morning 8 AM.
The interviewer was very friendly provided with various hints.
It was covering complex coding questions on Tree Data Structures.
I first thought of DFS, and BFS approaches but then tried using heap but couldn't solve since the approach was wrong.
Since I messed up in the first question and already wasted a lot of time. I couldn't come u with any approach.
FOR LDS https://www.codingninjas.com/codestudio/problems/longest-decreasing-subsequence_800300?leftPanelTab=3