摘要: 阅读全文
posted @ 2018-12-17 16:33 巨象 阅读(305) 评论(0) 推荐(0)
摘要: 阅读全文
posted @ 2018-12-17 16:31 巨象 阅读(272) 评论(0) 推荐(0)
摘要: 阅读全文
posted @ 2018-12-17 16:27 巨象 阅读(123) 评论(0) 推荐(0)
摘要: 阅读全文
posted @ 2018-12-17 15:38 巨象 阅读(321) 评论(0) 推荐(0)
摘要: 第二种办法比较常用: %02d print '%02d' % 11 阅读全文
posted @ 2018-12-17 15:17 巨象 阅读(351) 评论(0) 推荐(0)
摘要: 阅读全文
posted @ 2018-12-17 15:16 巨象 阅读(116) 评论(0) 推荐(0)
摘要: 比较常用的就是%s %d %f 阅读全文
posted @ 2018-12-17 15:04 巨象 阅读(121) 评论(0) 推荐(0)
摘要: int(x [,base ]) 将x转换为一个整数 long(x [,base ]) 将x转换为一个长整数 float(x ) 将x转换到一个浮点数 complex(real [,imag ]) 创建一个复数 str(x ) 将对象 x 转换为字符串 repr(x ) ... 阅读全文
posted @ 2018-12-17 11:07 巨象 阅读(354) 评论(0) 推荐(0)