Created
May 15, 2021 15:56
-
-
Save dongwooklee96/ee95024c912b814b8ee68cdb967828f8 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 solve(numbers: list): | |
tot = sum(numbers) | |
if tot == 0: | |
return 0 | |
elif tot > 0: | |
return '+' | |
elif tot < 0: | |
return '-' | |
if __name__ == '__main__': | |
for i in range(3): | |
n = int(input()) | |
numbers = [] | |
for j in range(n): | |
numbers.append(int(input())) | |
print(solve(numbers)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment