Lowest value
Arr = Array(5,2,6,333)
for i = 0 to ubound(Arr)
if Arr(i) < Arr(0) Then
Arr(0) = Arr(i)
End if
next
msgbox Arr(0) 'output 2
Highest value
Arr = Array(5,2,6,333)
for i = 0 to ubound(Arr)
if Arr(i) < Arr(0) Then
Arr(0) = Arr(i)
End if
next
msgbox Arr(0) 'output 333
Arr = Array(5,2,6,333)
for i = 0 to ubound(Arr)
if Arr(i) < Arr(0) Then
Arr(0) = Arr(i)
End if
next
msgbox Arr(0) 'output 2
Highest value
Arr = Array(5,2,6,333)
for i = 0 to ubound(Arr)
if Arr(i) < Arr(0) Then
Arr(0) = Arr(i)
End if
next
msgbox Arr(0) 'output 333
No comments:
Post a Comment