def to_char_map(set):
    out = {}
    for pos, val in enumerate(sorted(set)):
        out[val] = 1-pos
    return out
dataset/ETHPy150Open huangz1990/riacn-code/ch07_listing_source.py/to_char_map/swapped operands of `-`