1 python 变量和简单数据类型

print("打印内容")

valname = "变量"

str = "str"
str1 = 'str'

print(str.title()) #首字母大写
print(str.upper()) #全部大写
print(str.lower()) #全部小写

str3 = f"使用变量内容{str}"
print(str3)

print("\t这是空格符或制表符")
print("\n这是换行符")

str4 = "  aaaaaa"
str5 = "bbbb    "
str6 = "     bbbb    "
print(str5.rstrip())
print(str4.lstrip())
print(str6.strip())

numb = 2
numb1 = 0.2
numb2= 1111_44444_55555
x,y,z = 1,33,55
MNU_CC = "这是常量"

发表评论

邮箱地址不会被公开。