# Reduce size of list by 2 elements. values = values[:-2] print(values) [10, 20, 30, 40, 50] [10, 20, 30]