Tip 1 : Practice Atleast 250 Questions from coding ninjas
Tip 2 : Ex- Do atleast 2 good projects
Tip 1 : Have some good projects on resume.
Tip 2 : Do not put false things on resume and be confident.
2 coding questions related to data structures



1. Return the final answer by doing a mod with 10^9 + 7.
2. Pairs {A, B} and {B, A} are considered the same.



1. Each student gets at least one book.
2. Each book should be allocated to only one student.
3. Book allocation should be in a contiguous manner.
Input: ‘n’ = 4 ‘m’ = 2
‘arr’ = [12, 34, 67, 90]
Output: 113
Explanation: All possible ways to allocate the ‘4’ books to '2' students are:
12 | 34, 67, 90 - the sum of all the pages of books allocated to student 1 is ‘12’, and student two is ‘34+ 67+ 90 = 191’, so the maximum is ‘max(12, 191)= 191’.
12, 34 | 67, 90 - the sum of all the pages of books allocated to student 1 is ‘12+ 34 = 46’, and student two is ‘67+ 90 = 157’, so the maximum is ‘max(46, 157)= 157’.
12, 34, 67 | 90 - the sum of all the pages of books allocated to student 1 is ‘12+ 34 +67 = 113’, and student two is ‘90’, so the maximum is ‘max(113, 90)= 113’.
We are getting the minimum in the last case.
Hence answer is ‘113’.
Debugging round.
A C Code of Infix to Postfix Conversion was provided, 90-100 lines of code



Infix notation is a method of writing mathematical expressions in which operators are placed between operands.
For example, "3 + 4" represents the addition of 3 and 4.
Postfix notation is a method of writing mathematical expressions in which operators are placed after the operands.
For example, "3 4 +" represents the addition of 3 and 4.
Expression contains digits, lower case English letters, ‘(’, ‘)’, ‘+’, ‘-’, ‘*’, ‘/’, ‘^’.
Input: exp = ‘3+4*8’
Output: 348*+
Explanation:
Here multiplication is performed first and then the addition operation. Hence postfix expression is 3 4 8 * +.
To convert infix expression to postfix expression, we will use the stack data structure. By scanning the infix expression from left to right, when we will get any operand, simply add them to the postfix form, and for the operator and parenthesis, add them in the stack maintaining the precedence of them.
To-and-Fro on what challenges faced as per multiple processors or multi-threads.
Explained a bug where malloc initiated system lock and some other signal tried to acquire the lock, a race condition. And the methodology of how to find the source of the problem and asynchronous tasks at the core of it.



1. A binary tree is a tree in which each node has at most two children.
2. The given tree will be non-empty.
3. The given tree can have multiple nodes with the same value.
4. If there are no nodes in the tree which are at distance = K from the given node, return an empty list.
5. You can return the list of values of valid nodes in any order. For example if the valid nodes have values 1,2,3, then you can return {1,2,3} or {3,1,2} etc.

Consider this tree above. The target node is 5 and K = 3. The nodes at distance 1 from node 5 are {2}, nodes at distance 2 from node 5 are {1, 4} and nodes at distance 3 from node 5 are {6, 3}.

Here's your problem of the day
Solving this problem will increase your chance to get selected in this company
What is recursion?