Print an Array
From CompSciWiki
Back to the Program-A-Day homepage
ProblemPrint an array using a for loop |
Introducing Array | |
---|---|---|
SolutionCreate an array that has 10 elements array = [0,1,2,3,4,5,6,7,8,9,10] Use for loop to print these elements for element in array: print element | ||
Code |