Victor Subervi <victorsube...@gmail.com> writes: > What I need to calculate is the length of days in the given month. How > do I do that?
The ‘datetime’ module focusses on individual date+time values (and the periods between them, with the ‘timedelta’ type). For querying the properties of the calendar, use the ‘calendar’ module. Yes, it would be nice if the ‘time’, ‘datetime’, and ‘calendar’ modules were all much more unified and consumed a common set of primitive date+time types. It's a wart, and fixing it would (unfortunately) probably require backward-incompatible API changes. -- \ “Simplicity is prerequisite for reliability.” —Edsger W. | `\ Dijkstra | _o__) | Ben Finney -- http://mail.python.org/mailman/listinfo/python-list