Guest User

Python flatten

a guest
Jul 9th, 2024
73
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.08 KB | None | 0 0
  1. def flatten(list_of_lists):
  2.     return [x for xs in list_of_lists for x in xs]
  3.  
Advertisement
Add Comment
Please, Sign In to add comment