小编Gan*_*yak的帖子

为什么在Python中使用'%04.3f'?

我遇到了以下代码。

print ('%04.3f' % random.uniform(1, 100))
Run Code Online (Sandbox Code Playgroud)

'%04.3f'代码中代表什么?

python string-formatting

-1
推荐指数
1
解决办法
1052
查看次数

标签 统计

python ×1

string-formatting ×1