孕晚期上火怎么办:请高手教我用VB写个全排列的程序

来源:百度文库 编辑:神马品牌网 时间:2024/05/12 01:27:00

num是数组,里面是你需要排序的数字:
dim i,j,temp as integer 定义变量

For i = 1 To 10
For j = 1 To 10
If num(i) < num(j) Then
temp = num(i)
num(i) = num(j)
num(j) = temp
End If
Next j
Next i

这是我 所想的,可能有一点错误请谅解.
dim a,b,c,t as integer
private sub commmount_click()
if a<b then
a = b;a=c;t=b
else if a<c then
a=c;b=c;a=t
if b<c then
b=c;c=a;c=t
end sub
你用这个程序可以 随便;输入三个数字,以从大到小排序