Yes, I know this subject has been covered before: Python idiom to chain (flatten) an infinite iterable of finite iterables? Flattening a shallow list in Python Comprehension for flattening a sequence of sequences? How do I make a flat list out of a list of lists? but as far as I know, all solutions, except for one, fail on a list like [[[1, 2, 3], [4, 5]], 6], where the desired output is [1, 2, 3,