Answers for "how to make a list of lists in one list"

2

list of lists to single list python

flat_list = [item for sublist in t for item in sublist]
Posted by: Guest on August-03-2021
2

combine list of lists python

x = [["a","b"], ["c"]]

result = sum(x, [])
# This combines the lists within the list into a single list
Posted by: Guest on April-11-2021

Code answers related to "how to make a list of lists in one list"

Code answers related to "TypeScript"

Browse Popular Code Answers by Language