Programming Examples

Python program to print the largest number


Program to print the largest number 

Solution

num1=int(input("Enter the first number"))
num2=int(input("Enter the second number"))
num3=int(input("Enter the third number"))
max=num1
if num2>max:
 max=num2
if num3>max:
 max=num3
print("Largest number is:",max)
Output/ Explanation:

Enter the first number27

Enter the second number37

Enter the third number17

('Largest number is:', 37)

Latest Current Affairs 2024 Online Exam Quiz for One day Exam Online Typing Test CCC Online Test Python Programming Tutorials Best Computer Training Institute in Prayagraj (Allahabad) Online MBA 2 years Online MCA Online BCA Best Website and Software Company in Allahabad