更多"从键盘上输入XXYYZZXYZWXP和X,以下程序的输出结果是 [9]"的相关试题:
[填空题]从键盘上输入XXYYZZXYZWXP和X,以下程序的输出结果是 [9] 。
#include<iostream.h>
#include<string.h>
void main( )
char*str,ch;
int count=0,pos;
cin>>str>>ch;
pos=strlen(str)-1;
while(pos>=0)
if((str[pos])=ch)count++;
pos--;
cout<<"count="<<count;
[填空题]下列程序执行时,从键盘上依次输入123和234,则程序的输出结果是 【10】 。
Dim a,b As Integer
a=InputBox("请输入第一个整数")
b=InputBox("请输入第二整数")
Print a+b
[填空题]下列程序执行时,从键盘上依次输入123和234,则程序的输出结果是 【9】 。
a=InputBox("请输入第一个整数")
b=InputBox("请输入第二整数")
Print a+b
[填空题]以下程序的功能是:从键盘上输入若干个学生的考试分数,当输入负数时结束输入,然后输出其中的最高分数和最低分数。请在 【8】 和 【9】 处填入适当的内容,将程序补充完整。
Private Sub Form_Click( )
Dim x As Single,amax As Single,amin As Single
x=Input Box("Enter a score")
amax=X
amin=x
Do While 【8】
If x>ama x Then
Ama x=x
End lf
If 【9】 Then
amin=X
End lf
x=Input Box("Enter a score")
Loop
Print”Max=";amax,"Min=";amin
End Sub
[填空题]若从键盘输入70,则以下程序输出的结果是【 】。
#include<iostream.h>
void main( )
{ int a;cin>>a;
if(a>50) cout<<a;
if(a>40)cout<<a;
if(a>30)cout<<a}
[填空题]若从键盘输入70,则以下程序输出的结果是 【8】 。
#include<iostream.h>
void main( )
{
int a; cin>>a;
if(a>50) cout<<a;
if(a>40) cout<<a;
if(a>30) cout<<a;
}