3 control flow and looping


#1

this is what i have done could someone help

p2>
a = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13]
print a


#2

hi @rickgrimeszombieslay,

please read and follow the instructions carefully :slight_smile:

The instructions given are:

  1. Like step 2 above, loop through each item in the list called a.
  2. Like step 3 above, if the number is even, print it out. You can test if the item % 2 == 0 to help you out.

#3

a = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13]
for number in a:
if number % 2 == 0:
print number