I am trying to do the following in a concise way:
n = 3
lst1 = [[] for _ in range(n)]
lst2 = [[] for _ in range(n)]
lst3 = [[] for _ in range(n)]
Basically generating a number of list of empty lists with the same size.
I am looking for a one-liner on this one. I tried using zip
and various itertools
but I must admit this set of features is one of my weak links with Python.