Tip 1 : Practice all standard questions again and again
Tip 2 : Do good number of medium and hard number of problems
Tip 3 : Focus on core subjects, specially operating system
Tip 1 : Do not put false things on resume.
Tip 2 : Resume should have operating systems as core topics
Tip 3 : Put interview experience if you have
Tip 4 : Have atleast one project
5 mcqs related to pnc, probability, statistics
3 coding questions



String ‘P’ is lexicographically smaller than string ‘Q’, if :
1. There exists some index ‘i’ such that for all ‘j’ < ‘i’ , ‘P[j] = Q[j]’ and ‘P[i] < Q[i]’. E.g. “ninja” < “noder”.
2. If ‘P’ is a prefix of string ‘Q’, e.g. “code” < “coder”.
N = 4
A = [ “ab” , “abc” , “a” , “bp” ]
Explanation :
Only prefix of the string “a” is “a” which is present in array ‘A’. So, it is one of the possible strings.
Prefixes of the string “ab” are “a” and “ab” both of which are present in array ‘A’. So, it is one of the possible strings.
Prefixes of the string “bp” are “b” and “bp”. “b” is not present in array ‘A’. So, it cannot be a valid string.
Prefixes of the string “abc” are “a”,“ab” and “abc” all of which are present in array ‘A’. So, it is one of the possible strings.
We need to find the maximum length string, so “abc” is the required string.



Dynamic Programming
The idea is to use a bottom-up dynamic programming approach instead of a memoization approach. In this, we also have two choices whether to select or not. If we select then we take the occurrences of that number and the value stored at dp[i-2] as dp[i-1] will be deleted and not be taken to count. If we do not select the number then we take dp[i-1] which have been already calculated.



Input: arr[] = {1,1,1,2,2,2}
Output: {1,2,1,2,1,2}
Note: {2,1,2,1,2,1} is also valid because there are no two adjacent elements which are the same.
Greedy with Priority Queue
One coding question
some general talk
questions on operating system



Can you solve each query in O(logN) ?
There are many approaches posible
1.sort array
2.find position where it is sorted
3.binary search
(3 is the optimized one)
What is the concept of reentrancy?
What is catche memory?
What is aging in Operating System?
3 puzzles
1 coding ques
general discussion



Consider ARR = [“coding”, ”codezen”, ”codingninja”, ”coders”]
The longest common prefix among all the given strings is “cod” as it is present as a prefix in all strings. Hence, the answer is “cod”.
sort the vector
and then check b/w first and last
10 Coins Puzzle
You are blindfolded and 10 coins are placed in front of you on the table. You are allowed to touch the coins but can’t tell which way up they are by feel. You are told that there are 5 coins head up, and 5 coins tails up but not which ones are which. Can you make two piles of coins each with the same number of heads up? You can flip the coins any number of times.
There is a room with a door (closed) and three light bulbs. Outside the room, there are three switches, connected to the bulbs. You may manipulate the switches as you wish, but once you open the door you can’t change them. Identify each switch with its bulb. All bulbs are in working condition.

Here's your problem of the day
Solving this problem will increase your chance to get selected in this company
How do you remove whitespace from the start of a string?