Created
January 19, 2018 12:45
-
-
Save Fhernd/39a57e1e93e1d4ae570a314f687b242a to your computer and use it in GitHub Desktop.
Hora y fecha actuales.
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
import datetime | |
# Hora y fecha actuales: | |
hora_actual = datetime.datetime.now() | |
print(hora_actual) | |
print(hora_actual.year) | |
print(hora_actual.month) | |
print(hora_actual.day) | |
print() | |
print(hora_actual.date()) | |
print(hora_actual.time()) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment