Created
October 25, 2015 16:27
-
-
Save popey456963/6326a2f11724f6bc6425 to your computer and use it in GitHub Desktop.
Odd One Out
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
numbers = input().split(" ") | |
j = [] | |
for i in numbers: | |
j.append(int(i)) | |
count = 0 | |
for i in j: | |
if i < 0: | |
count = count - 1 | |
else: | |
count = count + 1 | |
if count > 0: | |
print(min(j)) | |
if count < 0: | |
print(max(j)) |
Author
popey456963
commented
Nov 5, 2015
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment