-
-
Save parzibyte/a78ef2ad4b4cf4fc79a0ebd4ec447913 to your computer and use it in GitHub Desktop.
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_numero_decimal(base_origen, numero): | |
if base_origen == "2": | |
return conversiones.binario_a_decimal(numero) | |
elif base_origen == "8": | |
return conversiones.octal_a_decimal(numero) | |
elif base_origen == "10": | |
return int(numero) | |
elif base_origen == "16": | |
return conversiones.hexadecimal_a_decimal(numero) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment