15. Program segment: int num=2; while (NUM)
printf ("%d,", num--); The result is _______________ A. 2,1, B. 2,1 C. 2,1,0 D. 2,1,0,
16. If there is a description: int a[3][4],s, then the elements of the array a reference is correct ____________ a. s=0; for (i=0;i<=3;i++) for (j=0;j<4;j++) s+=a[i][j]; B. s=0; for (j=0;j<=4;j++) for (i=0;i<3;i++) s+=a[i][j]; C. s=0; for (i=0;i<4;i++) for (j=0;j<=3;j++) s+=a[j][i]; D. s=0; for (i=0;i<3;i++) for (j=0;j<4;j++) s+=a[i][j];
17. If the parameter gets the address of the argument, ____________ is the argument when the function is called. A. array name B. global amount
c. The value of all elements in the array D. the number of elements in the array
18. If there is a definition:inti,j,*pi=&i; , then the comparison expression with i==j equivalence is ____________ a. i==*pi b. *pi ==*&j c. i==&j d. i==**pi
19. If there is a definition: struct person{ int id char name[20]; } per,*s=&per;
The following references to struct members are the correct ____________ a. per.name[0] b. s->name[0] c. per.name[8] d. per.id
A. #include (stdio.h) b. #include [stdio.h] c. #include {stdio.h} D. #include <stdio.h>
22. A variable definition statement char A; The following assignment statement is correct. A. a= ' & '; B. A= "&"; C. a= "; D. a= ' 16 '
23. with Char ch; With the statement "Ch=getchar ();" The equivalent statement is:. A. printf ("%c", ch); B. printf ("%c", &ch); C. scanf ("%c", ch); D. scanf ("%c", &ch);
C Language Exercise 4