读下列程序,写出程序的运行结果。#include void fun(int x, int y);int a=5, b=8;int main( ){int a=15;fun(a, b);printf("a=%d, b=%d\n", a, b);}void fun(int x, int y){int temp;if(a>b){temp=a;x=y;y=temp;}}输出:
查看答案
读下列程序,写出程序的运行结果。#include double fact(int n);int main(){ int n;scanf ("%d", &n);printf ("%.0f\n", fact (n) );return 0;}double fact(int n){double result;if (n==1 || n == 0)result = 1;elseresult = n * fact(n-1);return result;}输入:5输出:
读下列程序,写出程序的运行结果。#include void PrintStar (int m);int main (void){int i, n;scanf("%d", &n);for(i = 1; i <= n; i++)PrintStar(i);return 0;}void PrintStar (int m){int i;for (i = 1; i <= m; i++)putchar('*');putchar ('\n');}输入:5输出:
发动机负荷增大,最佳点火提前角也应增大,该说法( )A、错B、对
土基应先将开挖基础时预留下来的保护层挖除,并清除杂物,然后用碎石垫底,盖上湿砂,再进行压实,浇()cm厚素混凝土垫层。
A. 4~8
B. 8~12
C. 12~20
D. 20~30