下列VBA程序段的执行结果为 。 I = 1 Do While I<=10 SUM = SUM + I I = I + 1 Loop Debug.Print SUM
举一反三
- 下面程序运行后的结果为___ Private Sub Form_Click() Dim i%, sum% i = 1 Do While i < 5 sum = sum + i * i i = i + 2 Loop Print sum End Sub A: 45 B: 35 C: 10 D: 25
- 执行循环后,两变量 I, Sum 分别是: Dim I As Short = 1 Dim Sum As Long = 0 Do While I <= 5 Sum += I I = I + 2 Loop
- 以下程序段的执行结果是______。 int s=0,i=1; do { S+=i++; } while(i<=10); Console.WriteLine("sum={0}",sum); A: sum=54 B: sum=1 C: sum=55 D: sum=30
- 智慧职教: 看程序,写结果main() { int i,sum=0; i = 1; do { sum = sum +2; i++; } while (i<100); printf("%d",sum); }
- 看程序,写结果 main() { int i,sum=0; i = 1; while (i < 100) { sum = sum + i; i++; } printf("%d",sum); }