Greatest Among Four Numbers
Given four integers, write a program to print the greatest value among the four numbers.
Input
The first line of input will be an integer.
The second line of input will be an integer.
The third line of input will be an integer.
The fourth line of input will be an integer.
Output
The output should be a single line containing the greatest number.
Explanation
For example, if the given numbers are 5, 3, 7, 2. As 7 is the greatest among the four numbers, so the output should be 7.
Test Case 1:-
Input:-
5
3
7
2
Output:-
7
Test Case 2:-
Input:-
11
11
11
11
Output:-
11
We need all test cases can be came when code was run. I want exact outputs for all test cases
numbers=[]
for i in range(0,4):
number=int(input())
numbers.append(number)
print(max(numbers))
Comments
Exlent
Dear Hari nadh babu, You're welcome. We are glad to be helpful. If you liked our service please press like-button beside answer field. Thank you!
Awesome! Great excellent. Thank u!
Leave a comment