题目内容

此程序的功能为求2*24*246,根据功能将程序补充完整。#include int main(){int n= 0,p=1,i;i=2;while(i<=6){n=;p=;i=i+2;}printf("p=%d",p);return 0;}

查看答案
更多问题

(1)有2处错误,请找出并将其改为正确形式。(2)若输入123↙,程序的运行结果为。#include void main(){char c;while((c=getchar())!='\n')switch (c-'1'){case 0: putchar(c); break;case 1: putchar(c+2);case 2: putchar(c+1); break;case 3: putchar(c+2);case 4: putchar(c-1); break;default: putchar(c);}return 0;}

此程序实现的功能是。#include int main(){unsigned int re(unsigned int m);unsigned int n,r;scanf("%u",&n);if(n!=0)r=re(n);elser=0;printf("%u",r);return 0;}unsigned int re(unsigned int m){unsigned int b=0;while(m){b=b*10+m%10;m/=10;}return b;}

(1)运行程序后会输出 。(2)*(pa+i) 实现什么作用?#include int main(){char a[]="programming";char b[]="language";int i;char *pa,*pb;pa=a;pb=b;for(i=0;i<7;i++){if(*(pa+i)!=*(pb+i))printf("%c",*(pa+i));}printf("\n");return 0;}

此程序实现的功能是 。#include int main(){char a[100],b[100],*p,*q;int m;gets(a);scanf("%d",&m);p=a;q=b;for(p=p+m-1;*p!='\0';p++,q++)*q=*p;*q='\0';printf("%s",b);return(0);}

答案查题题库