A: include
B: include
C: include
D: include
举一反三
- Which of the following program is right? ( ) A: #include<br/>int main();<br/>{ /*programming*/<br/>printf("programming!\n");<br/>return 0;<br/>} B: #include<br/>int main()<br/>{ /*programming*/<br/>printf("programming!\n");<br/>return 0;<br/>} C: include <br/>void main()<br/>{ /*programming*/ <br/>printf("programming!\n");<br/>return 0;<br/>} D: #include<br/>int mian()<br/>{ /*programming*/<br/>printf("programming!\n");<br/>return 0;<br/>}
- 以下程序没有语法问题的是() A: B: include<;stdio.h>;int main( ){int x , y = 5 ; printf( "%d\n" , x / y ) ; return 0 ;} C: D: include<;stdio.h>;int main( ){int x = 3 ;y = 5 ; printf( "%d\n" , x / y ) ; return 0 ;} E: F: include<;stdio.h>;int main( ){int x = 3 ,y ; printf( "%d\n" , x / y ) ;y = 5; return 0 ;} G: H: include<;stdio.h>;int main( ){int x = 3 , y = 5 ; printf( "%d\n" , x / y ) ; return 0 ;}
- 以下程序中,运行结果是36的有()。 A: include <stdio.h> B: define M(y) y*y int main() { printf("%d\n",M(6+0)); return 0; } C: include <stdio.h> D: define M(y) (y)*(y) int main() { printf("%d\n",M(6+0)); return 0; } E: include <stdio.h> int M(int y) { return y*y; } int main() { printf("%d\n",M(6+0)); return 0; } F: include <stdio.h> int M(int y) { return (y)*(y); } int main() { printf("%d\n",M(6+0)); return 0; }
- 以下程序正确的是_____ A: B: include<;stdio.h>;int gNum;gNum=13;void main(){printf("%d\n", gNum);} C: D: include<;stdio.h>;void main(){int rob=17;printf("rob=%d\n", rop);}int rop=71; E: F: include<;stdio.h>;void main(){extern int outer;printf("outer=%d\n", outer);}int outer=33; G: H: include<;stdio.h>;void main(){extern int outer=33;printf("outer=%d\n", outer);}int outer=33;
- 执行以下程序后,输出结果为。#include<;stdio.h>;int n;void f();int main(){n=0;f();n=n+2;printf("%d\n",n);return 0;}void f(){n=n+5;}
内容
- 0
以下程序的执行结果是()#include<stdio.h>int main(){printf("1** #2# ");printf(" 789 ");return 0;}
- 1
执行以下程序后,输出结果第一行为,第二行为。#include<;stdio.h>;int n=0;void f();int main(){int n;n=2;f();printf("%d\n",n);return 0;}void f(){n=n+5;printf("%d\n",n);}
- 2
以下程序的运行结果是________。 #include <stdio.h> int main() { int a=12345,b=1234; float c=34567.899; printf("%4d\n",a); printf("%d\t%s\n",b,"Welcome"); printf("%10.2f\n",c); return 0; }
- 3
以下程序运行后的输出结果是_______。#include<;stdio.h>;int f(int n){if(n==0||n==1) return 1;elsereturn n+f(n-1);}int main(){printf(“%d\n”,f(0));printf(“%d\n”,f(1));printf(“%d”,f(5));}
- 4
中国大学MOOC: 以下程序输出的结果是()# include <stdio.h>int main(){ int a = 4; switch(a ) { case 0: printf("this is 0\n"); break; case 1: printf("this is 1\n"); break; case 2: printf("this is 2\n"); break; default: printf("this is default\n"); } return 0;