摘要:
字符工厂函数str() class str(object): """ str(object='') -> str str(bytes_or_buffer[, encoding[, errors]]) -> str Create a new string object from the given o 阅读全文
posted @ 2016-10-17 16:00
wangmo
阅读(707)
评论(0)
推荐(0)
摘要:
1、数字 整数int:比如2 长整数long:不过是大一些的整数 浮点数float:3.23和52.3E-4,E标记表示10的幂。在这里,52.3E-4表示52.3 * 10-4 复数complex:(-5+4j)和(2.3-4.6j),其中-5,4为实数,j为虚数 2、布尔值 真或假 1 或 0 阅读全文
posted @ 2016-10-17 14:20
wangmo
阅读(241)
评论(0)
推荐(0)
摘要:
1.循环输出1-10 1 1 2 2 3 3 4 4 5 5 6 6 7 7 8 8 9 9 10 10 2.break用法,break为跳出整个当前循环层,只跳一层。当i=5的时候退出 1 1 2 2 3 3 4 4 5 5 3.for+else用法,如果for循环正常结束,则执行else 1 2 阅读全文
posted @ 2016-10-17 09:57
wangmo
阅读(352)
评论(0)
推荐(0)