编写程序,实现功能:通过双向排序,使数组元素a(1)到a(n)升序排列。
Const n =10
Dim a(1 To n)As Integer
‘随机生成10个1-100之间的数存储在数组a中,代码略
For i=1 to n\2
For j= ⑴ To i+1 Step-1
If a(j)<a(j-1)Then t = a(j):a(j)=a(j-1):a(j-1)=t
Next j
For k=i+1 To ⑵
If a(k)>a(k +1)Then t =a(k):a(k)= a(k +1):a(k+1)=t
Next k
Next i
划线处可选代码为:①2 ②n-i+1 ③n ④n-i
则(1)、(2)处语句依次为( )