Computer Science, asked by liveasjoseph, 4 months ago

write a python code to find greatest of two numbers​

Answers

Answered by Anonymous
4

ANSWER:-

Program Explanation:

Get two inputs num1 and num2 from user using input() method check whether num1 is greater than num2 using if statement. if num1 is greater print num1 using print() method, else check whether num2 is greater than num1 using elseif statement.

➜Python Program to Find the Largest Among Three Numbers

# Python program to find the largest number among the three input numbers.

# take three numbers from user.

num1 = float(input("Enter first number: "))

num2 = float(input("Enter second number: "))

num3 = float(input("Enter third number: "))

if (num1 > num2) and (num1 > num3):

largest = num1.

Similar questions