Having error when using list in dictionary

Presumably you mean this?

switches_path = {'s1': [], 's2': [], 's3': [], 's4': []}
adjs = {'s1': ['s2', 's4'], 's2': ['s1', 's3'], 's3': ['s2', 's4'], 's4': ['s1', 's3']}

Leave a Comment