Write a Python program to print three numbers in Descending Order.

 a=int(input("Enter first number:"))

b=int(input("Enter second number:"))

c=int(input("Enter third number:"))


max=mid=min = None


if a>b and a>c:

    if b>c:

        max,mid,min=a,b,c

    else:

        max,mid,min=a,c,b


elif b>a and c>a:

    if b>c:

        max,mid,min=b,c,a

    else:

        max,mid,min=c,b,a



else:

    if c>a:

        max,mid,min=c,a,b

    else:

        max,mid,min=b,a,c


print("The Descending order of three no. is:", max,mid,min)


Comments

Popular posts from this blog

QUANTUM NUMBERS (Principal, Azimuthal, Magnetic and Spin)

Diagonal Relationship between Beryllium and Aluminium || Relation between Beryllium and Aluminium

Math question

Solar System, Planets, Moons, Asteroid Belt,Kuiper Belt and Oort Cloud, Comets and Meteoroids