Given an array of integers nums of length n. Find an integer P such that there are exactly P elements in array that are greater than P and P need not be an element from array.
Example:
Input: [1, 3, 4]
Output: 2
Explanation: There are exactly 2 elements in array that are greater than two and 2 is not present in the array.