There were 4 questions and time was 90 minutes. Questions were easy.
- Given a string and q queries in the form "L R ch" return the occurrences of ch from L to R. The string can be repeated for ex :- string = "aab", query = "1 10 b". Answer would be 3 as string will eventually become "aabaabaaba". Thus the string may be repeated any number of times.
- This was just based on sorting on basis of length of strings. We just need to find the first match of length of given string and last match. For ex :- {a, bb, bc, cd, af, ccd, cfghr}, given string = cd. So the first and last occurences are 2 and 5. After this just there was some arithmetic operation to be done.
- This was also based on sorting(Greedy).
- Convert a Binary Tree into its Mirror Tree.