python基础知识(二)&基本命令

python的基本命令 一、基本运算 能够把python当成计算器来看待,打开python的shell脚本。python >>> a=4#赋值 >>> b=5 >>> a+b 9 >>> a*2#乘法 8 >>> a**2#幂 16 >>> a,b,c=2,3,4#至关于a=2,b=3,c=4 #字符串的灵活操做 >>> s='I like python' >>> s+'very much!'
相关文章
相关标签/搜索