DekGenius.com
Home
(current)
Dictionary
BOOKS
LYRICS
CHORD
SCRIPT & CODE EXAMPLE
Karaoke language
Search
Go
SCRIPT & CODE EXAMPLE
CODE EXAMPLE FOR PYTHON
python flatten list
my_list
=
[
[
1
]
,
[
2
,
3
]
,
[
4
,
5
,
6
,
7
]
]
flat_list
=
sum
(
my_list
,
[
]
)
print
(
flat_list
)
Source by www.programiz.com #
PREVIOUS
NEXT
Tagged:
#python
#flatten
#list
ADD COMMENT
Topic
COMMENT
Name
6+3 =
Submit