有以下程序#includemain(){inti=5;do{if(i%3==1)if(i%5==2){printf("*%d",i);break;}i++;}while(i!=0);printf("");}程序的运行结果是( )。
举一反三
- 有以下程序段,其运行结果是_______inti=5;do{if(i%3==1)if(i%5==2){printf(*%d,i);break;}i++;}while(i!=0);
- 有以下程序,运行结果是()#include<stdio.h>main(){inti=5;do{if(i%3==1)if(i%5==2){printf("*%d",i);break;}i++;}while(i!=0);printf("\n");}(3.0分)
- 以下程序的运行结果是 inti = 0, s = 0; for( ; ; ) { if(i == 3 || i == 5) continue; if(i == 6) break; i++;s += i; } printf("%d",s);
- 以下程序的运行结果是#includemain(){ints[12]={1,2,3,4,4,3,2,1,1,1,2,3},c[5]={0},i;for(i=0;i<12;i++)c[s[i]]++;for(i=1;i<5;i++)printf(“%d”,c[i]);printf(“”);}
- 下面程序执行后的输出结果是()。#includeintmain(){inti=0,s=0;for(;;){if(i==3||i==5)continue;if(i==6)break;i++;s+=i;};printf("%d",s);return0;}#includeintmain(){inti=0,s=0;for(;;){if(i==3||i==5)continue;if(i==6)break;i++;s+=i;};printf("%d",s);return0;}#includeintmain(){inti=0,s=0;for(;;){if(i==3||i==5)continue;if(i==6)break;i++;s+=i;};printf("%d",s);return0;}#includeintmain(){inti=0,s=0;for(;;){if(i==3||i==5)continue;if(i==6)break;i++;s+=i;};printf("%d",s);return0;} A: 10 B: 13 C: 21 D: 死循环