What is the cleanest way to implement the following:
list = [list1, list2, ...]
return [*list1, *list2, ...]
It looks like this syntax will be available in Python 3.5. In the meantime, what is your solution?
This is commonly written as:
[x for l in list for x in l]
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With