重要提示:请勿将账号共享给其他人使用,违者账号将被封禁!
查看《购买须知》>>>
首页 > 大学专科> 电子信息
网友您好,请在下方输入框内输入要搜索的题目:
搜题
拍照、语音搜题,请扫码下载APP
扫一扫 下载APP
题目内容 (请给出正确答案)
[主观题]

有下列程序: include<stdio.h> yoidfun(int*a.intn)/*fun函数的功能是将a所指数组元素从大到小

有下列程序: include<stdio.h> yoidfun(int*a.intn)/*fun函数的功能是将a所指数组元素从大到小排序*/ {intt,i’j; for(i=0;i<n-1;j++) for(j=i+1j<nj++) if(a[i]<a[j]){t=a[i];a[i]=a[jl;a[j]=t;} } main() {intc[10]={1,2,3,4,5,6,7,8,9,0),i; fun(c+4,6); for(i=0;i<10;i++)pfintf(%d,,c[i]); printf(\n); } 程序的运行结果是

A.1,2,3,4,9,8,7,6,5,0,

B.0,9,8,7,6,5,1,2,3,4,

C.0,9,8,7,6,5,4,3,2,1,

D.1,2,3,4,5,6,7,8,9,0

答案
查看答案
更多“有下列程序: include<stdio.h> yoidfun(int*a.intn)/*fun函数的功能是将a所指数组元素从大到小”相关的问题

第1题

有下面的程序: include <stdio, h> main () { enum team {my,your=4,his,her=his+10};

有下面的程序: include <stdio, h> main () { enum team {my,your=4,his,her=his+10}; prinff(" % d %d %d %d \n" ,my,your,his,her); 此程序的输出结果是【 】。 A) 0 1 2 3 B) 0 4 0 1 0 C) 0 4 5 1 5 D) 1 4 5 1 5

点击查看答案

第2题

以下程序运行后输出结果是【 】。 include <stdio, h> main() { int a,b,c; a=10; b:20

以下程序运行后输出结果是【 】。 include <stdio, h> main() { int a,b,c; a=10; b:20; c=(a%b<1) ‖ (a/b>1); printf("%d %d %d\n",a,b,c); }

点击查看答案

第3题

以下程序运行后的输出结果是【 】。 include <stdio, h> main() { int a

以下程序运行后的输出结果是【 】。 include <stdio, h> main() { int a=3,b=4,c=5,t=99; if(b<a && a<c) t=a;a=c;c=t; if(a<e && b<c) t=b;b=a;a=t; printf("%d %d %d \n" ,a,b,e); }

点击查看答案

第4题

以下程序运行后的输出结果是【 】。 include <stdio, h> main() char c1 ,c2; for(e

以下程序运行后的输出结果是【 】。 include <stdio, h> main() char c1 ,c2; for(el = 0, c2 =9; e1<c2; c1 + + , c2 -- ) printf(" %c%c", c1, c2 ); printf("\n" ); }

点击查看答案

第5题

以下程序运行后的输出结果是【 】。 include <stdio, h> include <string, h> main() { char

以下程序运行后的输出结果是【 】。 include <stdio, h> include <string, h> main() { char ch[] ="abc".,x[3] [4]: int i: for(i=0;i<3:i ++) strcpy(x[i] ,ch): for(i =0;i<3:i++) printf("% s" ,&x[i] [i]); printf(" \n" ) }

点击查看答案

第6题

以下程序运行后的输出结果是【 】。 include <stdio, h> main () { char a [

以下程序运行后的输出结果是【 】。 include <stdio, h> main () { char a [ ] = "Language", b [ ]: "Programe"; char * pl, * p2; int k; p1=a;p2=b; for(k=0;k<=7;k++) if(* (p1 +k) == * (p2+k)) printf("% c", * (pi +k)); }

点击查看答案

第7题

以下程序运行后的输出结果是【 】。 include <stdio, h> main() { int a = 1,b =2,c =3;

以下程序运行后的输出结果是【 】。 include <stdio, h> main() { int a = 1,b =2,c =3; if(c = a) printf("% d \n" ,c); else printf("% d \n" ,b); }

点击查看答案

第8题

以下程序运行后的输出结果是【 】。 include <stdio, h> include <stating, h> void fun(char

以下程序运行后的输出结果是【 】。 include <stdio, h> include <stating, h> void fun(char * s,int p,int k) { int i; for(i=p;i<k-1;i++) s[i] =s[i+2]; } main() { char s [] = "abedefg"; fun(s,3 ,strlen(s) ); puts(s); }

点击查看答案

第9题

以下程序运行后输出结果是【 】。 include <stdio, h> void swap(int x.int y) { int t; t

以下程序运行后输出结果是【 】。 include <stdio, h> void swap(int x.int y) { int t; t = x;x = y;y = t: printf("% d % d ",x,y); } main () { iht a=3,b=4: swap(a,b); prinff("% d % d" ,a,b); }

点击查看答案

第10题

以下程序运行后的输出结果是【 】 include <stdio, h> fun(int a) { int b = 0; static in

以下程序运行后的输出结果是【 】 include <stdio, h> fun(int a) { int b = 0; static int c = 3; b++;c++; return(a + b + c); } main() int i,a = 5; for(i =0;i <3;i ++ ) prinff("% d% d" ,i,fun(a) ); printf(" \n" ); }

点击查看答案

第11题

以下程序从终端读入数据到数组中,统计其中正数的个数,并计算它们之和,请填空。 include <s
tdio, h> main() int i, a [20], sum, count; sum = count = 0 ; for(i=0;i<20;i++)scanf("%d",【 】); for(i=0;i<20;i ++) {if(a[i] >0) { count + +; sum+ = 【 】; } prinff("sum = % d, count = % d \ n", sum, count ); }

点击查看答案
下载APP
关注公众号
TOP
重置密码
账号:
旧密码:
新密码:
确认密码:
确认修改
购买搜题卡查看答案 购买前请仔细阅读《购买须知》
请选择支付方式
  • 微信支付
  • 支付宝支付
点击支付即表示同意并接受了《服务协议》《购买须知》
立即支付 系统将自动为您注册账号
已付款,但不能查看答案,请点这里登录即可>>>
请使用微信扫码支付(元)

订单号:

遇到问题请联系在线客服

请不要关闭本页面,支付完成后请点击【支付完成】按钮
遇到问题请联系在线客服
恭喜您,购买搜题卡成功 系统为您生成的账号密码如下:
重要提示:请勿将账号共享给其他人使用,违者账号将被封禁。
发送账号到微信 保存账号查看答案
怕账号密码记不住?建议关注微信公众号绑定微信,开通微信扫码登录功能
请用微信扫码测试
优题宝