On 03/06/2015 22:16, Alex Kleider wrote:
On 2015-06-03 12:53, Alan Gauld wrote:
...
If this is really about parsing dates and times have
you looked at the datetime module and its parsing/formatting
functions (ie strptime/strftime)?
I asssume strftime gets its name from 'string from time.'
What about strptime? How did that get its name?
'f' for format, 'p' for parse, having originally come from plain old C.
More here
https://docs.python.org/3/library/datetime.html#strftime-and-strptime-behavior
As Alan has hinted at earlier in this thread, if you're using dates
and/or times it's certainly far easier to use the built-in functions
rather than try to roll your own.
--
My fellow Pythonistas, ask not what our language can do for you, ask
what you can do for our language.
Mark Lawrence
_______________________________________________
Tutor maillist - Tutor@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor