摘要: 1、检索文件夹大小的程序,要求执行方式如下 python3.8 run.py 文件夹 import osimport sys def get_file_size(files_list, size=0): for file in files_list: if not os.path.isfile(fi 阅读全文
posted @ 2020-03-30 22:44 凌醉枫 阅读(150) 评论(0) 推荐(0) 编辑
摘要: time模块 时间模块优先掌握的操作 一:timeimport time 时间分为三种格式: 1、时间戳:从1970年到现在经过的秒数 作用:用于时间间隔的计算 print(time.time()) 2、按照某种格式显示的时间:2020-03-30 11:11:11 作用:用于展示时间 print( 阅读全文
posted @ 2020-03-30 19:28 凌醉枫 阅读(361) 评论(0) 推荐(0) 编辑
摘要: 小说阅读器 启动模块bin/start.py 1 import os 2 import sys 3 4 BASE_PATH=os.path.dirname(os.path.dirname(__file__)) 5 sys.path.append(BASE_PATH) 6 7 8 from core 阅读全文
posted @ 2020-03-30 08:27 凌醉枫 阅读(461) 评论(0) 推荐(0) 编辑