python开发_calendar
发布时间:2020-12-17 00:19:01 所属栏目:Python 来源:网络整理
导读:如果你用过linux,你可能知道在linux下面的有一个强大的 功能,即日历 在 中,同样也有这样的一个强大的 下面是我做的 : year = 2013 month = 8 test_month = ( * 50 ( == main() Python 3.3.2 (v3.3.2:d047928ae3f6,May 16 2013,00:03:43) [MSC v.1600 32
如果你用过linux,你可能知道在linux下面的有一个强大的功能,即日历 在中,同样也有这样的一个强大的 下面是我做的:
year = 2013
month = 8
test_month = ( * 50
(
== main()
Python 3.3.2 (v3.3.2:d047928ae3f6,May 16 2013,00:03:43) [MSC v.1600 32, >>> ================================ RESTART ================================
>>>20131 2 3 4
5 6 7 8 9 10 11
12 13 14 15 16 17 18
19 20 21 22 23 24 25
26 27 28 29 30 31
<span style="color: #008000;"># <span style="color: #008000;">#################################################<span style="color: #000000;">2013这一年是否为闰年?:False (3,31<span style="color: #000000;">) [[0,1,2,3,4],[5,6,7,8,9,10,11],[12,13,14,15,16,17,18],[19,20,21,22,23,24,25],[26,27,28,29,30,31<span style="color: #000000;">,0]] >>> 再附上的源码:
= [,, ,,,, ,,,, ,,,,
error =
self.month = %
self.weekday = %
January = 1
February = 2
mdays = [0,31,31
_months = [datetime.date(2001,i+1,1).strftime i range(12 _months.insert(0, x:
self.format =
funcs = [f(self.format) f
13
_days = [datetime.date(2001,1,i+1).strftime i range(7
self.format =
funcs = [f(self.format) f |