Time constants module - standard-library fodder?
bignose-hates-spam at and-zip-does-too.com.au
Sun Jun 1 12:17:58 CEST 2003
On 31 May 2003 16:34:25 -0700, Dan Bishop wrote:
> Ben Finney wrote:
>> Many programmers in many languages break the "use named constants"
>> rule, but one of the most egregious examples seems to be constants
>> for number of seconds in an hour, day, week, etc.
>> Is there a better way? A standard module I've missed?
> In Python 2.3, yes. Take at look at the datetime.timedelta class.
Excellent! Thanks very much, now I don't have to duplicate the effort
by refining my module :-)
\ "When I was a little kid we had a sand box. It was a quicksand |
`\ box. I was an only child... eventually." -- Steven Wright |
http://bignose.squidly.org/ 9CFE12B0 791A4267 887F520C B7AC2E51 BD41714B
More information about the Python-list