1.输入a=input()
b=int(input())
c=float(input())
a, b, c = list(map(int, input().split()))
# 输入1 2 3
进制转换
print(bin(2)) #type =str
>'0b10'
>
[python round]https://www.runoob.com/python/func-number-round.html
2.除法 10/3 3.3333333333333335
9/3 3.0
10//3 3
10%3 1
3.判断and
or
not
4.字符串str
类
len('ABC') # 求字符串长度
print(f'{
s:.2f}') #s后余两个小数点
a=int("3") #字符串转int
a=float("3.0") #字符串转float
a.lower() #转小写字母
a.upper()#转大写字母
a.replace('a', 'A')
a.endswith(obj, beg=0, end=len(string))
a.startswith(obj, beg=0,end=len(string))
a.isdigit()
a.lstrip() #截掉 string 左边的空格
a.rstrip()#删除 string 字符串末尾的空格.
a.strip()#在 string 上执行 lstrip()和 rstrip()
a.split() #以空白分割字符
a.splitlines() # 以换行符分割字符
s = " fwef fw f "
print(s.split("f")) # [' ', 'we', ' ', 'w ', ' ']
print(s.split()) #['fwef', 'fw', 'f']
5.列表list
类
a=[1,2,3]
len(a)
a[0] 1
a[-1] 3
a.append(4