-
变电所装有两台变压器时,每台主变压器的额定容量需满足______。()()A.()任一台变压器单独运行时,满足总计算负荷的需要B.()任一台变压器单独运行时,应满足全部一、二级负荷的需要。C.()任一台变压器单独运行时,满足总计算负荷的需要,同时也要满足全部一、二级负荷的需要。D.()单台变压器容量无要求
-
有以下程序 #include int main() { int x; scanf("%d",&x); if(x> printf("1"); else if(x> printf("2"); else if(x> printf("3"); } 若运行时输入:35,则输出结果是( )A.1B.2C.3D.123
-
阅读以下程序:#include <stdio.h>int main(){ int m;scanf("%d", &m);if (m >= 0) { if (m%2 == 0) printf("%d is a positive even", m); else printf("%d is a positive odd", m); }else { if (m % 2 == 0) printf("%d is a negative even", m); else printf("%d is a negative odd", m); }}运行时,若输入-9,则运行结果为( )。选项: A:-9 is a positive even; B:-9 is a positive odd; C:-9 is a negative even; D:-9 is a negative odd
-
若运行时输入-9,则以下程序的运行结果是
int m;
scanf("%d", &m);
if (m >= 0)
{ if (m%2 == 0) printf("%d is a positive even\n", m);
else printf("%d is a positive odd\n", m);
}
else
{ if (m % 2 == 0) printf("%d is a negative even\n", m);
else printf("%d is a negative odd\n", m);
} 选项: A:A. -9 is a positive even B:B. -9 is a positive odd C:C. -9 is a negative even D:D. -9 is a negative odd
-
下面程序运行时,如果从键盘输入: YDG?N?<回车>,则输出结果是____#include<stdio.h>int main(){char c;while((c=getchar())!='?') putchar(--c);return 0; }
-
以下程序运行时,若输入5,则程序的输出结果是().#include int fun(int n){if(n==1)return 1;else return n+fun(n-1);}int main(){int m;scanf("%d",&m);m=fun(m);printf("%d\n",m);}
-
以下程序运行时,输出结果是________________________。#include <stdio.h>main( ){int s, i, sum(int);for(i=1; i<=5; i )s=sum(i);printf("%d\n", s);}sum( int k){static int x=0;return x =k;}
-
以下程序运行时输出到屏幕的结果为: 。
#include <stdio.h>
void main ( )
{ int i , j, row=0, colum=0, max;
int a[3][4]={{1,2,3,4},{9,10,15,8},{-10,20,-5,2}};
max=a[0][0];
for (i=0; i<=2; i++)
for(j=0; j<=3;j++)
if (a[i][j]>max)
{max=a[i][j];
row=i;
colum=j;
}
printf ("max=%d,row=%d,colum=%d\n", max, row, colum);
}
-
以下程序运行时,从键盘上输入数字5,程序运行结果为_________。#include <;stdio.h>;int main(void){int i, n, sum,item=1;printf("Enter n: ");scanf("%d",&n);sum = 0;for ( i = 1; i <;= n; i=i+1 ){sum = sum + item;item=item+2;}printf( "sum = %d\n", sum);return 0;}
-
下面程序运行时输出结果中的第3行是什么。#include<stdio.h>int main(){ int i, j, a[3][3]={1},f1=0, f2=1, temp;for(i=1; i<3; i++)for(j=0; j<=i; j++){ if(j<=i){ a[i][j]=f1+f2;temp=f1; f1=f2; f2=f1+temp;}}for(i=0; i<3; i++){ for(j=0;j<3; j++)printf("%2d", a[i][j]);printf("
");}return 0;}