Last active
October 24, 2017 23:07
-
-
Save ysnerdem/ec9f32785ae67a77b548454c1e3d03a4 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
print('Please enter numbers') | |
print('You can terminate by entering -1 when you enter as many numbers as you want') | |
numbers = [] | |
while True: | |
num = int(input('Number:')) | |
numbers.append(num) | |
if num == -1: | |
break | |
max=0 | |
for i in numbers: | |
if i > max: | |
max = i | |
print('Largest number:',max) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment