任意输入5个数,按照由小到大的次序打印
请帮我写出来,谢谢!急着用
请帮我写出来,谢谢!急着用
解决方案 »
- vb怎样读取EXCEL指定行的数据
- 在VB中如何打SQLserver数据库打包进去?
- 服务端能否"催促"客户端发连接(connect方法)请求,以缩短侦听时间?
- 想问一个有关滞纳金公式的问题。题目见内容。
- 怎样使用VB编写纯ASP程序并封装成ActiveX DLL
- 怎么把引用的控件,动态链接文件打到包里啊?请教大侠,谢谢
- 文本的更新与导入问题。
- 用datareport对象为何无法实时更新数据!急!
- 请问如何编程把自己的代码编成EXE文件!
- 求VB.net能用的 延迟函数,不会假死的那种(不想用Timer),文中已经有VB6的代码了,会修改的请进
- 请问:怎样用ADO创建一个数据库(ACCESS 2000)
- 关于MDI的最大化的问题!解决立即送分!!
Dim intNum(4) As Integer
Dim intTmpNum As Integer
Dim i As Integer
Dim j As Integer
Randomize
For i = 0 To 4
intNum(i) = Int(Rnd() * 1000)
Next i
For i = 0 To 3
For j = i + 1 To 4
If intNum(i) > intNum(j) Then
intTmpNum = intNum(i)
intNum(i) = intNum(j)
intNum(j) = intTmpNum
End If
Next j
Print intNum(i)
Next i
Print intNum(4)
End Sub
dim j as long
dim t as long
dim n(4) as long
for i=0 to 4
n(i)=int(rnd()*1000)
next i
for i=0 to 4
for j=0 to 3
if n(j)>n(j+1) then
t=n(j)
n(j)=n(j+1)
n(j+1)=t
end if
next j
next i
for i=0 to 4
print n(i)
next i