Python学习笔记1:数值和字符串

Python旅程第一站:

Python数值运算:

 

type( ) 打印类型

四种基本类型:int, float, str, bool

round( )  取整,四舍五入

.split( ) 分割;.replace( ) 替换

 .upper( ) 转大写  .lower( ) 转小写   .strip( )去除空格

猜你喜欢

转载自www.cnblogs.com/chickenwrap/p/9938175.html