priceRange = { 'A':5800, 'B':3700, 'C':9900 } lowtoHigh = sorted(priceRange, key=priceRange.get) print(lowtoHigh) hightoLow = sorted(priceRange, key=priceRange.get, reverse=True) print(hightoLow)
priceRange = { 'A':5800, 'B':3700, 'C':9900 } lowtoHigh = sorted(priceRange, key=priceRange.get) print(lowtoHigh) hightoLow = sorted(priceRange, key=priceRange.get, reverse=True) print(hightoLow)