Tip 1 : Practice at least 250 Questions
Tip 2 : Do at least 2 projects
Tip 3 : Practice Data Structures
Tip 1 : Have some projects on resume
Tip 2 : Do not put false things on resume
You can use any string of A multiple times.
A =[“coding”, ”ninjas”, “is”, “awesome”] target = “codingninjas”
Ans = true as we use “coding” and “ninjas” to form “codingninjas”
The idea is simple, we consider each prefix and search it in dictionary. If the prefix is present in dictionary, we recur for rest of the string (or suffix).
If the recursive call for suffix returns true, we return true, otherwise we try next prefix. If we have tried all prefixes and none of them resulted in a solution, we return false.
Input: 'list' = [1, 2, 3, 4], 'k' = 2
Output: 2 1 4 3
Explanation:
We have to reverse the given list 'k' at a time, which is 2 in this case. So we reverse the first 2 elements then the next 2 elements, giving us 2->1->4->3.
All the node values will be distinct.
Recursively traverse the linked list. When returning from each recursive call keep track of the node number, considering the last node as number 1, second last as number 2 and so on. This counting could be tracked with the help of a global or pointer variable. With the help of this count variable, print the nodes having a node number less than or equal to k.
It was in the evening and online
Tell us about yourself.
What do you know about the company?
Where do you see yourself in 5 years?
Are there any questions you want to ask us?
Here's your problem of the day
Solving this problem will increase your chance to get selected in this company
Which collection class forbids duplicates?