Created
March 28, 2014 15:06
-
-
Save drgarcia1986/9834938 to your computer and use it in GitHub Desktop.
Exemplo básico de como trabalhar com os métodos strptime e strftime da biblioteca datetime do python
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
__author__ = 'diego.garcia' | |
import datetime | |
dt = datetime.datetime.strptime('February 28, 2014, 7:05 AM', '%B %d, %Y, %I:%M %p') | |
print(dt.strftime("%d/%m/%Y %I:%M %p")) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment