The following statement is wrong ( ).
A C program can contain multiple functions with different names
B. A C program can only have one main function
C program in writing, there are strict indentation requirements, otherwise it can not be compiled through
D. The main function of C program must use main as the function name
查看答案
do while statement executes the loop body first and then judges the conditions. The loop body executes at least once.
while statement and do while statement have the same function
If the variable is defined correctly, there are the following sections: i=0;do printf("%d, ",i);while(i++); printf("%d\n",i); Its output is ( ).
A. 0,0
B. 0,1
C. 1,1
D. Program enters infinite loop
#includemain () {int a=1,b=2; while (a<6) {b+=a; a+=2; b%=10; } printf(“%d,%d\n”,a,b); } The output of the program is ( ).
A. 5,11
B. 7,1
C. 7,11
D. 6,1