Noble Integer

Given an integer array, find if an integer p exists in the array such that the number of integers greater than p in the array equals to p
If such an integer is found return 1 else return -1.

NOTE: You only need to implement the given function. Do not read input, instead use the arguments to the function. Do not print the output, instead return values as specified. Still have a doubt? Checkout Sample Codes for more details.
Start solving Noble Integer on Interview Code Editor
Sign Up
to access hints and editorial solutions for Noble Integer


Click here to start solving coding interview questions