Answers for "python iterate thourgh array"

2

python for loop in array

for i in foo:
  print(i) #outputs 'foo' then 'bar'
Posted by: Guest on April-07-2021
1

python array looping

array = ["Var1","Var2","Var3"]
for i in range(len(array)):
  print(array[i])
  
#Output#
#Var1
#Var2
#Var3
Posted by: Guest on March-07-2020

Python Answers by Framework

Browse Popular Code Answers by Language