Created
June 12, 2020 10:41
-
-
Save Svastikkka/436fcdf2dd968d5e39e4c2929e22721b to your computer and use it in GitHub Desktop.
This file contains hidden or 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
num=input() | |
x=[int(i) for i in num] | |
e=0 | |
o=0 | |
for i in range(0,len(x)): | |
if x[i]%2==0: | |
e=e+x[i] | |
else: | |
o=o+x[i] | |
print(e,o) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Sum of even & odd