Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- def main():
- #have the user input three numbers
- a, b, c = eval(input("Please input three numbers separated by commas: "))
- #make an if then statement sorting the three variables from highest to lowest
- #if statement when a is the highest value
- if(a > (b and c) and (b > c)):
- print(a, b, c)
- elif:(a > (b and c) and (c > b)):
- print(a, c, b)
- elif(b > (a and c) and (a > c)):
- print(b, a, c)
- elif:(b > (a and c) and (c > a)):
- print(b, c, a)
- elif(c > (a and c) and (a > b)):
- print(c, a, b)
- else:
- print(c, b, a)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement