Sort the flowers

Report a typo

Mrs. Smith works in a flower shop. Here you can see a table with the flower prices:

flower price, $
rose 0.75
lily 1.3
tulip 1
hyacinth 0.70

Mrs. Smith needs to sort prices in the descending order. Write a program to help her!

The input you will get is a list of numbers, e.g. [0.75, 1.3, 1, 0.70]. The result should be this list sorted in the descending order, [1.3, 1, 0.75, 0.7] for the example above. Please print the sorted list in the end.

Write a program in Python 3
# the following line creates a list from the input, do not modify it, please
prices = [float(price) for price in input().split()]

# your code below
___

Create a free account to access the full topic