Dim D As VariantDim E() As IntegerDo While A1 <> 0A1 = 0For i2 = 0 To UBound(D)If D(i2) > A1 ThenA1 = D(i2) End If 'D(i2) > A1Next 'i2 = 0ReDim Preserve E(i3) As Integer E(i3) = A1i3 = i3 + 1For i2 = 0 To UBound(D) If D(i2) = A1 ThenD(i2) = 0End If 'D(i2) > A1Next 'i2 = 0Loop'這是一個(gè)排序用的,把數(shù)組元素(D)大到小排序去重復(fù)的復(fù)制到另一個(gè)(E)。'問,為什么do while ...Loop 與 while ....wend 的輸出沒有區(qū)別?
這是一個(gè)排序用的,為什么兩個(gè)輸出沒有區(qū)別呢?
炎炎設(shè)計(jì)
2022-12-22 17:13:07