Tip 1: Code more until you enjoy it.
Tip 2: Study data structures.
Tip 1: Mention only what you are confident about.
Tip 2: Include the tools and technologies used in the project as well.



[1, 2, 3, 4] is a strictly increasing array, while [2, 1, 4, 3] is not.



Input: 'a' = [7, 12, 1, 20]
Output: NGE = [12, 20, 20, -1]
Explanation: For the given array,
- The next greater element for 7 is 12.
- The next greater element for 12 is 20.
- The next greater element for 1 is 20.
- There is no greater element for 20 on the right side. So we consider NGE as -1.



The Number of elements smaller than 4 on its right side is 2.
The Number of elements smaller than 2 on its right side is 1.
The Number of elements smaller than 1 on its right side is 0.
The Number of elements smaller than 5 on its right side is 0.
Hence the count array is [2,1,0,0]

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