Tip 1 : Practice from Leetcode, solve Leetcode medium level problems.
Tip 2 : Brush up computer fundamentals from subjects like OS, DBMS and CN.
Tip 3 : Have a good project or good internship experience and have in-depth knowledge regarding what you have done
Tip 1 : Have some projects on resume.
Tip 2 : Do not put false things on resume.



For this question, you can assume that 0 raised to the power of 0 is 1.
Write a program to find x to the power n (i.e., x^n). Take x and n from the user. You need to print the answer.
1. There are 100 doors in a row, all doors are initially closed. A person walks through all doors multiple times and toggle (if open then close, if close then open) them in following way: In first walk, the person toggles every door In second walk, the person toggles every second door, i.e., 2nd, 4th, 6th, 8th, … In third walk, the person toggles every third door, i.e. 3rd, 6th, 9th, … ……… ………. In 100th walk, the person toggles 100th door. Which doors are open in the end?
There are two empty bowls in a room. You have 50 white balls and 50 black balls. After you place the balls in the bowls, a random ball will be picked from a random bowl. Distribute the balls (all of them) into the bowls to maximize the chance of picking a white ball.




1. Make in-place changes, that is, modify the nodes given a binary tree to get the required mirror tree.
Given a binary tree, convert this binary tree into its mirror tree.
A binary tree is a tree in which each parent node has at most two children.
Mirror of a Tree: Mirror of a Binary Tree T is another Binary Tree M(T) with left and right children of all non-leaf nodes interchanged.



For a given string “BaaB”
3 possible palindrome partitioning of the given string are:
{“B”, “a”, “a”, “B”}
{“B”, “aa”, “B”}
{“BaaB”}
Every substring of all the above partitions of “BaaB” is a palindrome.
Given a string ‘str’. Find the minimum number of partitions to make in the string such that every partition of the string is a palindrome.



1. Rightmost element is always a leader.
2. The order of elements in the return sequence must be the same as the given sequence
The given sequence is 13, 14, 3, 8, 2 .
13 Not a leader because on the right side 14 is greater than 13.
14 lt is a leader because no one greater element in the right side.
3 Not a leader because on the right side 8 are greater than 3.
8 It is a leader because no one greater element on the right side.
2 It is a leader because it is the rightmost element in a sequence.
Hence there are 3 leaders in the above sequence which are 14, 8, 2.
Given a sequence of numbers. Find all leaders in sequence. An element is a leader if it is strictly greater than all the elements on its right side.
You are standing before two doors. One of the path leads to heaven and the other one leads
to hell. There are two guardians, one by each door. You know one of them always tells the truth
and the other always lies, but you don’t know who the honest one is and who the liar is.
You can only ask one question to one of them in order to find the way to heaven. What is the
question

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