Created
December 16, 2018 00:12
-
-
Save parzibyte/7e87e46fdd92d4b380707b6a2e12c65d to your computer and use it in GitHub Desktop.
Ejemplificar switch para obtener valor created by parzibyte - https://repl.it/@parzibyte/Ejemplificar-switch-para-obtener-valor
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
def obtener_nombre_dia(numero_dia): | |
dias = { | |
0: "Domingo", | |
1: "Lunes", | |
#Aquí los demás días... | |
} | |
return dias.get(numero_dia, "Desconocido") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment