摘要: Python字典包含了以下内置函数: dict = {'Name': 'roy', 'Age': 100} print("Age 值为 : %s" % dict.get('Age')) print("Sex 值为 : %s" % dict.get('Sex', "nan")) dict = {'Na 阅读全文
posted @ 2018-02-11 16:33 MrBug 阅读(372) 评论(0) 推荐(0) 编辑
摘要: Python元组包含了以下内置函数 阅读全文
posted @ 2018-02-11 16:30 MrBug 阅读(144) 评论(0) 推荐(0) 编辑
摘要: Python包含以下函数: 阅读全文
posted @ 2018-02-11 16:23 MrBug 阅读(184) 评论(0) 推荐(0) 编辑
摘要: Python 的字符串常用内建函数如下: capitalize()将字符串的第一个字符转换为大写 center(width, fillchar) count(str, beg= 0,end=len(string)) bytes.decode(encoding="utf-8", errors="str 阅读全文
posted @ 2018-02-11 16:00 MrBug 阅读(170) 评论(0) 推荐(0) 编辑
摘要: 数学函数 print(abs(-10)) 输出: 10 输出: 5 cmp(x, y) 输出: 2.718281828459045 输出: 100.0 输出: 4-5 import mathprint(math.log(100)) 输出: 4.605170185988092 输出: 2.0 impo 阅读全文
posted @ 2018-02-11 11:40 MrBug 阅读(278) 评论(0) 推荐(0) 编辑

人生就是一场战斗,唯有披荆斩棘,勇往直前!