Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

enter three numbers and find smallest number in python

a = int(input('Enter first number  : '))
b = int(input('Enter second number : '))
c = int(input('Enter third number  : '))

smallest = 0

if a < b and a < c :
    smallest = a
elif b < c :
    smallest = b
else :
    smallest = c

print(smallest, "is the smallest of three numbers.")
Source by pythonexamples.org #
 
PREVIOUS NEXT
Tagged: #enter #numbers #find #smallest #number #python
ADD COMMENT
Topic
Name
7+4 =