题目内容

int a,b; int *pointer_1,*pointer_2; float *pointer_3; The following assignment is correct ( ).

A. pointer_3=2000;
B. *pointer_1=&a;
C. pointer_1=&a;
D. pointer_3=&a;

查看答案
更多问题

#includemain() { int m=1,n=2,*p=&m,*q=&n,*r; r=p;p=q;q=r;printf("%d,%d,%d,%d\n",m,n,*p,*q); }The output of the program is ( ).

A. 1,2,1,2
B. 1,2,2,1
C. 2,1,2,1
D. 2,1,1,2

Pointer variables cannot be used to point to elements in a struct array.

The base type of the pointer variable must be the same as the type of the struct variable.

There is the following definitions: struct sk { int a; float b; } data,*p;p =&data;, the correct reference to member a of data is ( )

A. (*p).data.a
B. (*p).a
C. p->data.a
D. p.data.a

答案查题题库