Control flow & Looping - Error "Your code should have printed 0, but did not"


#1

My code is

a = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13]
for number in a:
if number % 2 == 0:
print "The number is even number : " + str(number)

It gives output as

The number is even number : 0
The number is even number : 2
The number is even number : 4
The number is even number : 6
The number is even number : 8
The number is even number : 10
The number is even number : 12

and still I am getting error as "Oops, try again. Your code should have printed 0, but did not!"


#2

Get rid of some of the print part
print number will work perfectly


#3

Thanks Dear, it worked.