以下程序输出结果是()DimiAsIntegerDima()AsIngeger={1,2,3,4,5}Fori=LBound(a)toUBound(a)a(i)=a(i)*a(i)NextiConsole.WriteLine(a(i))
举一反三
- 有如下程序代码,输出结果是________。Dima()a=Array(1,2,3,4,5)fori=Lbound(a)toUbound(a)printa(i);nextI A: 12345 B: 01234 C: 54321 D: 43210
- 以下程序输出的结果是: Private Sub Form_Activate() Dim a a=Array(1,2,3,4,5) For i=Lbound(((A) To Ubound(((A) A(i)=i*a(i) Next i Print i, Lbound(((A) , Ubound(((A) , a(i) End Sub
- 执行下面的程序,消息框的输出结果是______。 option Base 1 PrivateSubCommandl_Click() Dima(10),P(3)As Integer K=5 Fori=1 To 10 a(i)=i Nexti Fori=1 To 3 p(i)=a(i*i) NextI Fori=1 To 3 k=k+p(i)*2 Ncxti MsgBoxk End sub
- 下面程序运行后,输出结果是( )。#include ;main( ){ int a[10]={1,2,3,4,5,6},i,j; for(i=0;i { j=a[i];a[i]=a[5-i];a[5-i]=j;} for(i=0;i}[/i][/i] A: 1 5 4 3 2 6 B: 1 5 3 4 2 6 C: 6 5 4 3 2 1 D: 1 2 3 4 5 6
- 以下程序段运行后的输出结果是()inti;for(i=1;i<=7;i++){if(i%2!=0)continue;printf("%d",i);} A: 2 4 6 B: 1 3 5 C: 1 3 5 7 D: 1 2 3 4 5 6 7