单选题
有如下程序 #include
#include
using namespace std; int main( ){ cout<
A、
setprecision(3)
B、
fixed
C、
setfill('*')
D、
setw(8)
【正确答案】
D
【答案解析】
解析:本题考查输入输出格式的控制,可以看出**12.345和**34.567字段宽度都为8,所以遗漏处为setw(8),D选项正确。
提交答案
关闭