def rank_items(items):
    """ Get a rank for each item that is computed by price/weight """
    for item in items:
        item['rank'] = (item['price'] * 1.0) / (item['weight'] * 1.0)  # I use 1.0 to get floats
    return items