Created
September 7, 2018 10:27
-
-
Save benslv/c301eafb26750e33c84da68b971dc32e to your computer and use it in GitHub Desktop.
2. Odd or Even
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
inpNumber = int(input("Please enter a number: ")) | |
if inpNumber % 4 == 0: | |
print("This number is divisible by 4.") | |
elif inpNumber % 2 == 0: | |
print("This number is even!") | |
else: | |
print("This number is odd.") | |
num = int(input("Please enter another number: ")) | |
check = int(input("One more, go on... ")) | |
if num % check == 0: | |
print("Yay!, "+str(num)+" is divisible by "+str(check)+".") |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment