I need to parse strings representing 6-digit dates in the format yymmdd
where yy
ranges from 59 to 05 (1959 to 2005). According to the time
module docs, Python's default pivot year is 1969 which won't work for me.
Is there an easy way to override the pivot year, or can you suggest some other solution? I am using Python 2.7. Thanks!
000229
would raise an error because2100/02/29
does not exist, even though2000/02/29
exists. – Unblushing