Even num


#1

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
else:
print "odd num %d" %number

I am getting invalid syntax


#2

Your if-statement is wrong. Correct:

if (number % 2 == 0):

#3

a = [0,1,2,3,4,5,6,7,8,9,10]
for number in a:
if (number%2==0):
print number
else:
print "%d number is odd" %(number)