上一页 1 ··· 573 574 575 576 577 578 579 580 581 ··· 640 下一页
摘要: 1、print,直接打印,比较简单而且粗暴 在代码中直接输入print+需要输出的结果,根据打印的内容判断即可 2、assert... 阅读全文
posted @ 2022-10-07 20:30 I'm_江河湖海 阅读(5) 评论(0) 推荐(0) 编辑
摘要: 在os模块中提供了两种调用 cmd 的方法,os.popen()和 os.system() os.system(cmd) 是在执行... 阅读全文
posted @ 2022-10-07 20:30 I'm_江河湖海 阅读(3) 评论(0) 推荐(0) 编辑
摘要: 在os模块中提供了两种调用 cmd 的方法,os.popen()和 os.system() os.system(cmd) 是在执行... 阅读全文
posted @ 2022-10-07 20:30 I'm_江河湖海 阅读(3) 评论(0) 推荐(0) 编辑
摘要: 创建有序字典 import collectionsdic = collections.OrderedDict()dic['k1'] ... 阅读全文
posted @ 2022-10-07 20:30 I'm_江河湖海 阅读(1) 评论(0) 推荐(0) 编辑
摘要: 创建有序字典 import collectionsdic = collections.OrderedDict()dic['k1'] ... 阅读全文
posted @ 2022-10-07 20:30 I'm_江河湖海 阅读(12) 评论(0) 推荐(0) 编辑
摘要: 这篇文章主要介绍了Python中使用item()方法遍历字典的例子,for...in这种是Python中最常用的遍历字典的方法了,需... 阅读全文
posted @ 2022-10-07 20:30 I'm_江河湖海 阅读(2) 评论(0) 推荐(0) 编辑
摘要: 这篇文章主要介绍了Python中使用item()方法遍历字典的例子,for...in这种是Python中最常用的遍历字典的方法了,需... 阅读全文
posted @ 2022-10-07 20:30 I'm_江河湖海 阅读(7) 评论(0) 推荐(0) 编辑
摘要: Collections 是 Python 内建的一个集合模块,提供了许多额外的数据类型。 namedtuple namedtuple... 阅读全文
posted @ 2022-10-07 20:30 I'm_江河湖海 阅读(4) 评论(0) 推荐(0) 编辑
摘要: Collections 是 Python 内建的一个集合模块,提供了许多额外的数据类型。 namedtuple namedtuple... 阅读全文
posted @ 2022-10-07 20:30 I'm_江河湖海 阅读(3) 评论(0) 推荐(0) 编辑
摘要: 1. sys.exit() 执行该语句会直接退出程序,这也是经常使用的方法,也不需要考虑平台等因素的影响,一般是退出Python程序... 阅读全文
posted @ 2022-10-07 20:30 I'm_江河湖海 阅读(13) 评论(0) 推荐(0) 编辑
上一页 1 ··· 573 574 575 576 577 578 579 580 581 ··· 640 下一页