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.
1. You can return the list of values in any order. For example, if a valid triplet is {1, 2, -3}, then {2, -3, 1}, {-3, 2, 1} etc is also valid triplet. Also, the ordering of different triplets can be random i.e if there are more than one valid triplets, you can return them in any order.
2. The elements in the array need not be distinct.
3. If no such triplet is present in the array, then return an empty list, and the output printed for such a test case will be "-1".
Given n biased coins, with each coin giving heads with probability Pi, find the probability that on tossing the n coins I will obtain exactly k heads. I had to write the formula for this (i.e. the expression that would give us P (n, k)).
Probability of getting K heads in N coin tosses can be calculated using below formula of binomial distribution of probability
1) Suppose we have three positive integers A, B, C. We randomly choose an integer a in the range [0,A] and an integer b in the range [0,B]. Find the probability that a + b<=C. 2) Repeat the above problem for the case when A, B, C are three positive real numbers.
2) Given a regular expression and a string (that apart from characters only contains *). Find whether the string satisfies the regular expression. Once the initial solution was given, a good amount of time was spent in considering all possible edge cases and tweaking the algorithm to solve those edge cases.
Assuming that each integer in given range has the same probability to be choosen, you have to count the cases when the inequality holds and divide it by all cases, namely:
∑Aa=0∑Bb=01(a+b≤C)(A+1)⋅(B+1)
What are relationships? How are they represented in a database?
What is indexing? Explain it with an example.
What is a hash table?
What is an IP address?
What is a MAC address?
If a MAC address exists why do we need an IP address?
Give the use cases of binary tree?
What is the advantage of an M-ary tree over binary tree?
The way you express yourself is really important. If you are unable to express yourself clearly or lack enthusiasm organizations would see that as a potential red flag. If you are weak in English, practice speaking in front of a mirror (believe me, it helps) or still better give mock interviews to your friends.
Think out aloud. Whatever idea comes to your mind, share it with the interviewer. Always start by giving a brute force solution to the problem (it helps the interviewer know that you have understood the problem).
Don’t give up on a problem until the last moment. Keep on discussing things with the interviewer; he will give you hints if you are on the right path.
Here's your problem of the day
Solving this problem will increase your chance to get selected in this company
Which array operation has O(n) worst-case time complexity?