03 2017 档案

摘要:记录python处理时间的模块:time模块、datetime模块和calendar模块。 python版本:2.7 在介绍模块之前,先说下以下几点: 1.时间通常有这几种表示方式: a.时间戳:通常是从1970年1月1日00:00:00开始按秒计算的偏移量,如:1488520142.802 b.格 阅读全文
posted @ 2017-03-06 14:08 蓝闪 阅读(3404) 评论(0) 推荐(0)
摘要:介绍python获取命令行参数的方法:getopt模和argparse模块。 python版本:2.7 一、getopt模块 主要用到了模块中的函数: options, args = getopt.getopt(args, shortopts, longopts=[]) 参数args:一般是sys. 阅读全文
posted @ 2017-03-02 14:36 蓝闪 阅读(27118) 评论(0) 推荐(1)