There was a dictionary I created and the value of the dict was a list. The sample code is below.
zigzag = dict.fromkeys(range(1, 4),[]) for i in range(1, 4):