I have a list of objects and I want to shuffle them. I thought I could use the random.shuffle method, but this seems to fail when the list is of objects. Is the
random.shuffle
The shuffling process is "with replacement", so the occurrence of each item may change! At least when when items in your list is also list.
E.g.,
ml = [[0], [1]] * 10
After,
random.shuffle(ml)
The number of [0] may be 9 or 8, but not exactly 10.