Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # Bigger and smaller number!
- n1 = int(input('Enter the first number: '))
- n2 = int(input('Enter the second number: '))
- n3 = int(input('Enter the third number: '))
- color = {'nothing' : '\033[m', 'green' : '\033[4;32m', 'yellow' : '\033[4;33m'}
- smaller= n1
- if (n2 > n1 and n2 > n3):
- smaller = n2
- if (n3 > n1 and n3 > n2):
- smaller = n3
- bigger = n1
- if (n2 < n1 and n2 < n3):
- bigger = n2
- if (n3 < n1 and n3 < n2):
- bigger = n3
- print('{}The number {} is the biggest!{}'.format(color['green'], bigger, color['nothing']))
- print('{}The number {} is the smallest!{}'.format(color['yellow'], smaller, color['nothing']))
- #by: Estéfani =D
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement