网友您好, 请在下方输入框内输入要搜索的题目:

题目内容 (请给出正确答案)
有如下程序: include include using namespace std; int ma

有如下程序: #include <iostream> #include <iomanip> using namespace std; int main() { cout.fill('*'); cout << left << setw(4) << 123 << "OK" << endl; return 0; }

A.123*OK

B.123*OK**

C.*123OK

D.*123**OK


参考答案

更多 “ 有如下程序: include include using namespace std; int ma 有如下程序: #include <iostream> #include <iomanip> using namespace std; int main() { cout.fill('*'); cout << left << setw(4) << 123 << "OK" << endl; return 0; }A.123*OKB.123*OK**C.*123OKD.*123**OK ” 相关考题
考题 有如下程序 include include using namespace std; int main( 有如下程序 #include<iostream> #include<iomanip> using namespace std; int main(){ cout<<setprecision(3)<<fixed<<setfill('*')<<setw(8); cout<<12.345<<_______<<34.567; return 0; } 若程序的输出是: ** 12.345**34.567 则程序中下划线处遗漏的操作符是A.setprecision(3)B.fixedC.setfill('*')D.setw(8)

考题 有如下程序 include include using namespace std; cla 有如下程序 #include <iostream> #include <iomanip> using namespace std; class MyClass { public: MyClass() { cout<<'A'; } MyClass(char c){ cout<<c; } ~MyClass(){ cout<<'B'; } }; int main( ) { MyClass p1,*p2; p2=new MyClass('X'); delete p2; return 0; } 执行这个程序屏幕上将显示输出A.ABXB.ABXBC.AXBD.AXBB

考题 有如下程序:include include using namespace std;int main(){cout.fill(' 有如下程序:#include <iostream>#include <iomanip>using namespace std;int main(){cout.fill('*');cout<<left<<setw(4)<<123<< "OK"<<end1;return 0;}执行这个程序的输出结果是( )。A.123*OKB.123*OK**C.*123OKD.*123**OK

考题 下面程序的执行结果是【】。 include include using namespace std; void main( 下面程序的执行结果是【 】。include<iostream>include<iomanip>using namespace std;void main(){cout<<setfill('x')<<setw(10);cout<<"Hello"<<endl;}

考题 如下程序的输出结果是includevoid fun(int x=y;y=t;}int main(){in 如下程序的输出结果是 #include<iostream> void fun(int & X,inty){intt=x;x=y;y=t;} int main( ){ int a[2]={23,42}; fun(a[1],a[0]); std::cout<<a[0]<<","<<a[1]<<std::endl; return 0; }A.42,42B.23,23C.23,42D.42,23

考题 有如下程序:includeincludeusing namespace std;int main( ){int S[ ]={12 有如下程序: #include<iostream> #include<iomanip> using namespace std; int main( ){ int S[ ]={123,234}; cout<<right<<setfill('*')<<setw(6); for(int i=0;i<2;i++){COUt<<s[i]<<endl;} return 0; } 程序的输出结果是A.123 234B.***123 234C.***123 ***234D.***123 234***

考题 有如下程序: include include using namespace std; int main() {cout.f 有如下程序: #include <iostream> #include <iomanip> using namespace std; int main() { cout.fill('*'); cout.width(6); cout.fill('#'); cout<<123<<end1; return 0; } 执行生的输出结果是( )。A. ###123B.123###C. ***123D.123***

考题 有如下程序include include using namespace std;int main( ){cout 有如下程序 #include <iostream> #include <iomanip> using namespace std; int main( ){ cout<<setprecision(3)<<fixed<<setfill('*')<<setw(8); cout<<12.345<<__________<<34.567; return 0; } 若程序的输出是: **12.345**34.567 则程序中下划线处遗漏的操作符是( )。A.setprecision(3)B.fixedC.setfill('*')D.setw(8)

考题 有如下程序:include includeusing namespace std;int main(){cout.fill('* 有如下程序:#include <iostream>#include<iomanip>using namespace std;int main(){ cout.fill('*'); cout.width(6); cout.fill('#'); cout<<123<<end1; return 0;}执行后的输出结果是( )。A.###123B.123###C.***123D.123***