Answers for "what is the function to add values to array in python"

1

how to add array in python

theArray = []

theArray.append(0)
print(theArray) # [0]

theArray.append(1)
print(theArray) # [0, 1]

theArray.append(4)
print(theArray) # [0, 1, 4]
Posted by: Guest on September-22-2021

Code answers related to "what is the function to add values to array in python"

Python Answers by Framework

Browse Popular Code Answers by Language