最近偶为了写一个调整时间的shell而绞尽脑汁,结果在某一天#info data这里面看到了data -d参数的灵活用法,真是欣喜若狂.好东西要保存,整理整理: * To print the date of the day before yesterday: date --date='2 days ago' * To print the date of the day three months and one day hence: date --date='3 months 1 day' * T…
http://www.cnblogs.com/Eva-J/articles/7228075.html 所有常用模块的用法 正则的规则: 在一个字符组里面枚举合法的所有字符,字符组里面的任意一个字符和‘带匹配字符’都相同,都视为可以匹配. #是数字 #11位 #以13|15|17|18|16|14 # num = input('phone_number : ') # if num.isdigit() and len(num) == 11 and num.startswith('13') or \…