Names by priority

orders is a list of (priority, name) tuples with distinct priorities. Write names_by_priority(orders) that returns the names ordered from lowest priority number to highest, using sorted.

names_by_priority([(3, "bread"), (1, "cake"), (2, "rolls")])  ->  ["cake", "rolls", "bread"]
def names_by_priority(orders):
    ...