Possible Duplicate:
Parse date and format it using python?
I hav开发者_开发百科e the following string in python:
2011-05-25T02:11:04Z
How can I convert it to
May, 25th 2:11
datetime.datetime.strptime('2011-05-25T02:11:04Z', '%Y-%m-%dT%H:%M:%SZ')
gives you a datetime.datetime
object with the correct date / time.
精彩评论