有以下程序:#include <iostream.h>#include void main(){ double d= 123.456789; cout<<setprecision(3)<<d<<","; cout<<setprecision(4)<<

admin2009-01-15  34

问题 有以下程序:#include <iostream.h>#include void main(){  double d= 123.456789;  cout<<setprecision(3)<<d<<",";  cout<<setprecision(4)<<d<<",";  cout<<setprecision(5 )<<d<<end1;}程序执行后的输出结果是(    )。

选项 A、123,123.4,123.45
B、123,123.5,123.46
C、123,123,123.4
D、123.456789,123.456789,123.456789

答案2

解析
转载请注明原文地址:https://kaotiyun.com/show/ljkp777K
0

最新回复(0)