网友您好, 请在下方输入框内输入要搜索的题目:

题目内容 (请给出正确答案)

有以下程序

#include <stdio.h>

main( )

{ int a[ ]={1,2,3,4},y,*p=&a[3];

--p; y=*p; printf("y=%d\n",y);

}

程序的运行结果是

A)y=0

B)y=1

C)y=2

D)y=3


参考答案

更多 “ 有以下程序#include stdio.hmain( ){ int a[ ]={1,2,3,4},y,*p=a[3];--p; y=*p; printf("y=%d\n",y);}程序的运行结果是A)y=0B)y=1C)y=2D)y=3 ” 相关考题
考题 有以下程序includemain(){inta[]={1,2,3,4},y,*p=a[3];--p;y=*p;printf("y=%d\n" 有以下程序 #include <stdio.h> main() { int a[]={1,2,3,4},y,*p=a[3]; --p; y=*p;printf("y=%d\n",y); } 程序的运行结果是A.y=0B.y=1C.y=2D.y=3

考题 有下列程序: include main() {int a[]={1,2,3,4},y,*p=a[3]; -- 有下列程序: #include <stdio.h> main() {int a[]={1,2,3,4},y,*p=a[3]; --p; y=*p; printf("y=%d\n",y); } 程序的运行结果是( )。A.y=0B.y=1C.y=2D.y=3

考题 请将以下程序中的函数声明语补充完整。 include int【】 main(){int x,y,(*p)(); sccanf(" 请将以下程序中的函数声明语补充完整。include<stdio.h>int【 】main(){ int x,y,(*p)();sccanf("%d%d",x,y);p=max;printf(%d\n",(*p)(x,y));}int max(int a,int b){return(a>b?a:b);}

考题 有以下程序 include void fun(int*a,int*B) { int*c; c=a;a=b;b=c; } main() {int x=3 有以下程序 #include<stdio.h> void fun(int*a,int*B) { int*c; c=a;a=b;b=c; } main() { int x=3, y=5,*p=x, *q=y; fun(p,q); printf("%d,%d,",*p,*q); fun(x,y); printf(" %d,%d\n",*p,*q); } 程序运行后的输出结果是______。A.3,5,5,3B.3,5,3,5C.5,3,3,5D.5,3,5,3

考题 有以下程序includestruct ord{ int x,y;} dt[2]={1,2,3,4};mare(){struct ord*p=dt; p 有以下程序 #include<stdio.h> struct ord { int x,y;} dt[2]={1,2,3,4}; mare() { struct ord*p=dt; printf("%d,",++p->x); printf("%d\n",++p->y); } 程序的运行结果是______。A.1,2B.2,3C.3,4D.4,1

考题 以下程序的输出结果是include "stdio.h"int *f(int *x,int *y){ if(*x*y) return x; else return y;}main(){ int a=7,b=8, *p,*q,*r ; p=a; q=b; r= f(p,q); printf("%d,%d,%d\n",*p,*q,*r);}

考题 有以下程序:includemain(){inta[]={1,2,3,4},y,*p=a[3];--p;y=*p;printf("y=%d\n 有以下程序: #include<stdio.h> main() {inta[]={1,2,3,4},y,*p=a[3]; --p;y=*p;printf("y=%d\n",y); } 程序的运行结果是( )。A.y=0B.y=1C.y=2D.y=3

考题 有以下程序:includemain(){int a[]={1,2,3,4},y,*p=--p;y=*p;printf("y=%d\n",y 有以下程序: #include<stdio.h> main() { int a[]={1,2,3,4},y,*p=&a[3]; --p;y=*p;printf("y=%d\n",y); } 程序的运行结果是( )。A.y=0B.y=1C.y=2D.y=3

考题 有以下程序includemain(){inta[]={1,2,3,4},y,*p=a[3]; --p;y=*p;printf("y=%d\n 有以下程序 #include <stdio.h> main() { int a[]={1,2,3,4},y,*p=a[3]; --p; y=*p;printf("y=%d\n",y); } 程序的运行结果是A.y=0B.y=1C.y=2D.y=3

考题 有以下程序:include void f(int * x,int * y) int t;t= *x; *x= *y; *y=t;main ( ){in 有以下程序:#include <stdio.h>void f(int * x,int * y) int t; t= *x; *x= *y; *y=t;main ( ){ int a[8] = { 1,2,3,4,5,6,7,8} ,i, * p, * q; p=a;q =a[7]; while(p<q) { f(p,q) ;p ++ ;q --; } for(i =0;i<8;i ++ ) printf(" % d," ,a[i]); }程序运行后的输出结果是( )。A.8,2,3,4.,5,6,7,1,B.5,6,7,8,1,2,3,4,C.1,2,3,4,5,6,7,8,D.8,7,6,5,4,3,2,1,