finished next highest number in array function. time for debuggin and comments.