Sub CHA()
Dim a As Range, s, res, i, iMin, iMax
s = Split("89 65 46 34 20 16", " ") '获取数据
ReDim res(LBound(s) To UBound(s))
For i = LBound(s) To UBound(s)
res(i) = Val(Right(s(i), 1))
Next
iMin = Application.WorksheetFunction.Min(res)
iMax = Application.WorksheetFunction.Max(res)
...
|