首页 > 其他分享 >std::cout 控制输出小数点位数

std::cout 控制输出小数点位数

时间:2022-10-31 17:35:27浏览次数:40  
标签:std 输出 cout 93972484 小数点 位数

转自:https://blog.csdn.net/zfjBIT/article/details/93972484

 

#include <iomanip>

 

std::cout << std::setiosflags(std::ios::fixed) << std::setiosflags(std::ios::right) << std::setprecision(3);

 

效果

 

标签:std,输出,cout,93972484,小数点,位数
From: https://www.cnblogs.com/5free/p/16845093.html

相关文章