以下C程序正确的运行结果是 。
main()
{ long y=-43456;
printf ("y=%-8ld
",y);
printf ("y=%-08ld
",y);
printf ("y=%08ld
",y);
printf ("y=%+8ld
",y);
}: y=-43456 y=-43456 y=-0043456 y=+□-43456|y=-43456 y=-43456 y=-0043456 y=□□-43456|y=□□-43456 y=-0043456 y=00043456 y=+434
main()
{ long y=-43456;
printf ("y=%-8ld
",y);
printf ("y=%-08ld
",y);
printf ("y=%08ld
",y);
printf ("y=%+8ld
",y);
}: y=-43456 y=-43456 y=-0043456 y=+□-43456|y=-43456 y=-43456 y=-0043456 y=□□-43456|y=□□-43456 y=-0043456 y=00043456 y=+434
举一反三
- 以下C程序正确的运行结果是 。 main() { long y=-43456; printf ("y=%-8ld\n",y); printf ("y=%-08ld\n",y); printf ("y=%08ld\n",y); printf ("y=%+8ld\n",y); }: y=-43456 y=-43456 y=-0043456 y=+□-43456|y=-43456 y=-43456 y=-0043456 y=□□-43456|y=□□-43456 y=-0043456 y=00043456 y=+43456|y=□□-43456 y=-□□43456 y=-0043456 y=-43456
- 以下C程序正确的运行结果是 。main(){ long y=-43456;...tf ("y=%+8ld",y);}
- 选择出合法的if语句(设intx,y;)()。 A: if(x!=y)if(x>y)printf("x>y\n"); else printf("x<y\n"); elseprintf("x==y\n"); B: if(x!=y) if(x>y)printf("x>y\n") else printf("x<y\n"); else printf("x==y\n"); C: if(x!=y)if(x>y)printf("x>y\n"); else printf("x<y\n") else printf("x==y\n"); D: if(x!=y) if(x>y) printf("x>y\n"); else printf("x<y\n") else printf("x= =y\n");
- 以下程序 void myfun (int y) { ++y; } main() { int y=3; myfun (y); printf(“%d”, y); } 的输出结果是______
- 【单选题】执行下面程序后,运行结果是() #include <stdio.h> main() { int x=41,y=1; if(x%3==0&&x%7==0) {y+=x; printf("y=%d ",y);} else {y=x; printf("y=%d",y);} } A. y=41 B. y=43 C. y=42 D. y=1