标签:完整 常用 binary 例子 单片机 ima list 浮点 ext
num_binary = 0b1010
print("num_binary is ", num_binary)
num_octonary = 0o567
print("num_octonary is ", num_octonary)
num_decimal = 789
print("num_decimal is ", num_decimal)
num_hexadecimal = 0xf7
print("num_hexadecimal is ", num_hexadecimal)
完整写法 | 偷懒写法 |
---|---|
3.0 | 3. |
0.5 | .5 |
number1 = 12.34
print(number1)
number2 = .9
print(number2)
number3 = 6.
print(number3)
n1 = 3 + 5j
n2 = 6j
n3 = (9J)
print(n1)
print(n2)
print(n3)
number = 99 + True
print(number)
标签:完整 常用 binary 例子 单片机 ima list 浮点 ext
原文地址:https://www.cnblogs.com/yorkyu/p/10223563.html