You are given N number of inputs. Print the maximum of them after each input.
list1 = []
N = int(input('Enter integer here: '))
for i in range(N):
s = eval(input('Enter no here:'))
list1.append(s)
print(max(list1))
Enter integer here: 4
Enter no here:5
5
Enter no here:5.2
5.2
Enter no here:4
5.2
Enter no here:6
6
Comments
Leave a comment