题目详情
当前位置:首页 > 职业培训考试
题目详情:
发布时间:2024-06-03 00:57:04

[填空题]以下程序的运行结果是 【8】 。 x=1.5 DO CASE CASE x>2 y=2 CASE x>l y=l ENDCASE y

更多"以下程序的运行结果是 【8】 。 x=1.5 DO C"的相关试题:

[填空题]以下程序的运行结果是 【8】
x=1.5
DO CASE
CASE x>2
y=2
CASE x>1
y=1
ENDCASE
y
[填空题]以下程序的运行结果是 【8】
x=1.5
DO CASE
CASE x>2
y=2
CASE x>1
y=1
ENDCASE
y
[填空题]以下程序运行后的输出结果是______。
main( )
int i=10,j=0;
do
j=j+i;i--;
while(i>2);
printf("%d/n",j);

[填空题]请在以下程序第一行的下划线处填写适当内容,使程序能正确运行。   【 】( double,double);   main( )   { double x,y;    scanf("%lf%lf",&x,&y);    printf("%lf/n",max(x,y));   }   double max(double a,double b)   { return(a>b a:b); }
[填空题]以下程序运行后的输出结果【 】。 struct NODE {int k; struct NODE *link; }; main( ) {structNODEm[5],*p=m,*q=m+4; int i=0; while(p!=q){ p->k=++i;p++; q->k=i++;q-; } q->k=i; for(i=0;i<5;i++)printf("%d",m[i].k); printf("/n"); }
[单项选择]以下程序运行后,单击按钮输出结果是
  Private Sub Commandl_Click( )
    Dim x As Integer,y As Integer,z As Integer
    X=4:y=2: Z=3
    Call Gopd(x,x,z)
    Print x;X;Z
    Call Gopd(x,y,y)
    Print x;y;y
  End Sub
  Private Sub Gopd(x As Integer,y As Integer,z As Integer)
    X=3 * Z + 1
    y=2 * z
    z=x + y
  End Sub
A. 6 6 12
B. 8 5 10
C. 9 6 12
D. 8 10 10
[填空题]以下程序运行后的输出结果是【 】。 struct NODE {int num;struct NODE *next; }; main( ) {struct NODE s[3]={{1,’’/0’’},{2,’’/0’’},{3,’’0’’}},*p,*q,*r; int sum=0; s[0].next=s+1;s[1].next=s+2;s[2].next=s; p=s; q=p->next; r=q->next; sum+=q->next->num; sum+=r->next->next->num; printf("%d/n",sum); }
[填空题]以下程序运行后的输出结果是 【17】 。 struct NODE { int k; struct NODE*link; }; main( ) { struct NODE m[5],*p=m,*q=m+4; int i=0; while(p!=q){ p->k=++i;p++; q->k=i++;q--; } q->k=i; for(i=0;i<5;i++)printf("%d",m[i].k); printf("/n"); }
[单项选择]以下程序运行后,单击按钮输出结果是( )。   Private Sub Commandl_Click( )     Dim x As Integer,y As Integer,z As Integer     X=4:y=2: Z=3     Call Gopd(x,x,z)     Print x;X;Z     Call Gopd(x,y,y)     Print x;y;y   End Sub   Private Sub Gopd(x As Integer,y As Integer,z As Integer)     X=3 * Z + 1     y=2 * z     z=x + y   End Sub
[填空题]以下程序运行后的输出结果是 【16】
struct NODE

int num;
stmct NODE *next;

main( )
struct NODE s[3]=1,’/0’),2,’/0’),3,’/0’),*p,*q,*r;
int sum=0;
s[0].next=s+1;
s[1].next=s+2;
s[2].next=s;
p=s
q=p->next;
r=q->next;
sum+=q->next->num;
sum+=r->next->next->num;
printf("%d/n",sum);

[填空题]以下程序运行后的输出结果是 【16】 。 struct NODE { int num; stmct NODE *next; }; main( ) {struct NODE s[3]={{1,’/0’),{2,’/0’),{3,’/0’}),*p,*q,*r; int sum=0; s[0].next=s+1; s[1].next=s+2; s[2].next=s; p=s q=p->next; r=q->next; sum+=q->next->num; sum+=r->next->next->num; printf("%d/n",sum); }
[填空题]以下程序运行后的输出结果是 【10】 。 #include <iostream> #include <string> using namespace std; class Y; class X { iht x; char *strx; public: X(int a,char *str) { x=a; strx=new char[strlen(str)+1]; strcpy(strx,str); } void show(Y &ob); }; class Y { private: iht y; char *stry; public: Y(int b,char *str) { y=b; stry=new char[strlen(str)+ 1] ; strcpy(stry, str); } friend void X::show(Y &ob); }; void X::show(Y &ob) { cout<<strx<<","; cout<<ob.stry<<endl; } int main( ) { X a(10,"stringX"); Y b(20,"stringY"); a.show(b); return 0; }
[填空题]以下程序运行后的输出结果是 【14】
#include <iostream>
#include <string>
using namespace std;
class Y;
class X

int x;
char *strx;
public:
X(int a,char *str)

x=a;
strx=new char[strlen(str)+1];
strcpy(strx,str);

void show(Y &ob) ;
;
class Y

private:
int y;
char *stry;
public:
Y(int b,char *str)

y=b;
stry=new char[strlen(str)+1];
strcpy(stry, str);

friend void X::show(Y &ob) ;
;
void X::show(Y &ob)

cout<<strx<<",";
cout<<ob.stry<<end1;

int main( )

X a(10,"stringX");
Y b(20,"stringY");
a. show (b) ;
return O;

[单项选择]以下程序运行后的输出结果是
#include<stdio.h>
#include<stdlib.h>
main( )
 int *a, *b, *c;
 a=b=c(int *) malloc(sizeof(int));
 *a=1; *b=2; *c=3;
 a=b;
 printf("%d, %d, %d/n", *a, *b, *c);

A. 3,3,3
B. 2,2,3
C. 1,2,3
D. 1,1,3

我来回答:

购买搜题卡查看答案
[会员特权] 开通VIP, 查看 全部题目答案
[会员特权] 享免全部广告特权
推荐91天
¥36.8
¥80元
31天
¥20.8
¥40元
365天
¥88.8
¥188元
请选择支付方式
  • 微信支付
  • 支付宝支付
点击支付即表示同意并接受了《购买须知》
立即支付 系统将自动为您注册账号
请使用微信扫码支付

订单号:

请不要关闭本页面,支付完成后请点击【支付完成】按钮
恭喜您,购买搜题卡成功
重要提示:请拍照或截图保存账号密码!
我要搜题网官网:https://www.woyaosouti.com
我已记住账号密码