import operator


def number_map_to_sorted_list(map_with_number_vals):
    """Given map_with_number_vals, a dictionary whose values are numbers, 
    return a list of the keys in the dictionary.
    The keys are sorted by the number value they map to, from greatest
    number down to smallest number.
    When two keys map to the same number value, the keys are sorted by their
    natural sort order for whatever type the key is, from least to greatest.
    """
    #sorts the dictionary by key in ascending order and turns it into a list of tuples
    map_with_number_vals = sorted(map_with_number_vals.items(),key = operator.itemgetter(0))
    #sorts the list of tuples in descending order by its value
    map_with_number_vals = sorted(map_with_number_vals, key = operator.itemgetter(1),reverse=True)
   
    map_with_number_vals_list = [i for i,j in map_with_number_vals]
    return map_with_number_vals_list