格式化输出只有固定小数点后位数

printf("%.2f",10.11111);

猜你喜欢

转载自blog.csdn.net/qianpeng4/article/details/78114895