# unpacking a list into variables. use variables instead of a list name
# date, name, price = ['December 23, 2015', 'Bread Gloves', 8.51]
# using *

def drop_first_last(grades):
    first, *middle, last = grades
    avg = sum(middle) / len(middle)
    print(avg)

drop_first_last([65, 76, 98, 54, 21])
drop_first_last([54, 98, 21, 45, 31, 98, 46])
