DekGenius.com
Home
(current)
Dictionary
BOOKS
LYRICS
CHORD
SCRIPT & CODE EXAMPLE
Karaoke language
Search
Go
SCRIPT & CODE EXAMPLE
CODE EXAMPLE FOR PYTHON
python sum array
# python: how to sum an array
array
=
[
1
,
1
,
2
,
0
,
-
1
]
sum_array
=
sum
(
array
)
print
(
sum_array
)
# 3
PREVIOUS
NEXT
Tagged:
#python
#sum
#array
ADD COMMENT
Topic
COMMENT
Name
9+8 =
Submit