I have a month variable which is a list of lists of tuples. Each list represents a week and each day is a tuple of the day of the month and the week day. I wish to make my month a list of lists of month days. I tried to do it like this:
for week in month:
week = [day[0] for day in week]
for [[(1, 1), (2, 2)], [(3, 3), (4, 4)]]
I expect to get [[1, 2], [3, 4]]
, but the list doesn't change. To my understanding of python my code is perfectly fine, so what am I missing? Isn't week
a reference to each week in the month?