Created
December 20, 2020 23:47
-
-
Save cechus/6a32c801f31bd0b6c3794fd744560ce0 to your computer and use it in GitHub Desktop.
Gift Problem
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 gift(n, m): | |
if m < n : | |
return "Intenta generar un nuevo número para que alcancen los regalos." | |
return "Cada niño recibirá %s regalos. Asi que la respuesta es %s" % (m//n, m//n*n) | |
print(gift(3, 10)) | |
print(gift(8, 10)) | |
print(gift(4, 3)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment