📅  最后修改于: 2022-03-11 14:55:57.294000             🧑  作者: Mango
# d, f, b and h are types
# integer
print(format(12, "d"))
# float arguments
print(format(123.4567898, "f"))
# binary format
print(format(12, "b"))
# hexadecimal format
print(format(12, "x"))