Exercise 3

Write a program in Python that asks the user to enter two numbers a and b and to display their maximum

Solution:

a = int(input("Type value of the number a : "))
b = int(input("Type value of the number b : "))

if (a > b):
print("The maximum of a and b is : a = ",a)
else:
print("The maximum of a and b is : b = ",b)

Younes Derfoufi
One thought on “Solution Exercise 3”

Leave a Reply