Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

python multiply each item in list

a = [1, 2, 3]
def multiray(a):
    return [i * 2 for i in a]
multiray(a)
# [2,4,6]
Source by www.kite.com #
 
PREVIOUS NEXT
Tagged: #python #multiply #item #list
ADD COMMENT
Topic
Name
2+3 =