[试题]

以下程序的输出结果是 _[9]_______ .

#include <stdio.h>

main()

{ int n=12345,d;

while(n!=0){ d=n%10; printf("%d",d); n/=10;}

}

参考答案与解析:

相关试题

试题10以下程序运行后的输出结果是______.#include <stdio.

[试题]试题10以下程序运行后的输出结果是______.#include <stdio.h>main(){char a;for(a=0; a<15; a+=5){putchar(a+’A’);}printf(“/n”);}

  • 查看答案
  • 试题11以下程序运行后的输出结果是______.#include <stdio.

    [试题]试题11以下程序运行后的输出结果是______.#include <stdio.h>void fun(int x){ if(x/5>0) fun(x/5)printf(“%d”, x);}main(){ fun(11); printf(“/n”);}

  • 查看答案
  • 试题13以下程序运行后的输出结果是______.#include <stdio.

    [试题]试题13以下程序运行后的输出结果是______.#include <stdio.h>main(){ int n[2], i, j;for(i=0; i<2;i++) n[i]=0;for(i=0; i<2; i++)for(j=0; j<2; j++) n[j]=n[i]+1;printf(“%d/n”, n[1]);}

  • 查看答案
  • (10)以下程序运行后的输出结果是 (10) 。#include <stdio.

    [主观题](10)以下程序运行后的输出结果是 (10) 。#include <stdio.h>main(){ int x=10,y=20,t=0;if(x==y)t=x;x=y;y=t;printf("%d %d/n",x,y);}

  • 查看答案
  • (13)以下程序运行后的输出结果是 (13) 。#include <stdio.

    [主观题](13)以下程序运行后的输出结果是 (13) 。#include <stdio.h>main(){ int i,n[5]={0};for(i=1;i<=4;i++){ n[i]==n[i-1]*2+1; printf("%d",n[i]); }printf("/n");}

  • 查看答案
  • (15)以下程序运行后的输出结果是 (15) 。#include <stdio.

    [主观题](15)以下程序运行后的输出结果是 (15) 。#include <stdio.h>main(){ FILE *fp; int x[6]={1,2,3,4,5,6},i;fp=fopen("test.dat","wb");fwrite(x,sizeof(int),3,fp);rewind(fp);fread(x,sizeof(int),3,fp);for(i=0;i<6;i++) printf("%d",x[i]);printf("/n");fclose(fp)

  • 查看答案
  • (14)以下程序运行后的输出结果是 (14) 。#include <stdio.

    [主观题](14)以下程序运行后的输出结果是 (14) 。#include <stdio.h>#include <stdlib.h>#include <string.h>main(){ char *p; int i;p=(char *)malloc(sizeof(char)*20);strcpy(p,"welcome");for(i=6;i>=0;i--) putchar(*(p+i));printf("/n "); free(p);}

  • 查看答案
  • 以下程序的输出结果是 _[12]_______ .#include <stdio

    [试题]以下程序的输出结果是 _[12]_______ .#include <stdio.h>main(){ int i;for(i='a';i<'f';i++,i++) printf("%c",i-'a'+'A');printf("/n");}

  • 查看答案
  • 以下程序的输出结果是 _[13]_______ .#include <stdio

    [试题]以下程序的输出结果是 _[13]_______ .#include <stdio.h>#include <string.h>char *fun(char *t){ char *p=t;return(p+strlen(t)/2);}main(){ char *str="abcdefgh";str=fun(str);puts(str);}

  • 查看答案
  • 以下程序的输出结果是 _[19]_______ .#include <stdio

    [试题]以下程序的输出结果是 _[19]_______ .#include <stdio.h>#define M 5#define N M+Mmain(){ int k;k=N*N*5; printf("%d/n",k);}

  • 查看答案
  • 以下程序的输出结果是 _[9]_______ .#include <stdio.