Can you identify the maximum value in an array?
Just out of educational curiosity... On an array with 1,000 numbers, I
found that using Max was a little faster than Large by about 20-30% .
--
Dana DeLouis
Windows XP & Office XP
= = = = = = = = = = = = = = = = =
"Brad Patterson" wrote in message
...
Dim Arr(5) as integer
Arr(2) = 99
Arr(3) = 101
How do I then find out what the maximum value is, and what position itıs
at
in this type of array * i.e. for the above, the maximum is 101, at
position
3.
Iıve had success with
Application.WorksheetFunction.Large(Arr, 1)
But still canıt get the position of that number.
Iım attempting this with an array that is 1000 in size if thatıs going to
be a problem ...
Thanks,
Brad.)
|