What's the easiest way to scan through an array or hash built with numbers (in a hash, the keys are numbers) and determine what the highest number is? For unique keys (I know other people will suggest other methods but this is what I chose and I like this method), I used numbers and to be sure I never accidently screw up I need to make sure it's +1 the greatest number it finds.
Can't just $num++ because I delete some hash keys/array values and doing so, the count would mess up and I'd overwrite hash keys. So I need to know the largest number in a hash (would be nice to know how this would work for an array as well, but it's probably the same thing) so I can add to it.
Thanks wise monks.