For your A


#1



Loops 12- For YOUR a


Oops, try again. Did you replace all of the "A"s and "a"s with "X"s? It looks like you printed "X b i r d i n t h e h X n d . . ." instead of "X b i r d i n t h e h X n d . . .".


Im not sure why this isnt correct


phrase = "A bird in the hand..."

# Add your for loop

for char in phrase:
    if char == 'A' or char == 'a':
        print 'X', " "
    else:
        print char," "

#Don't delete this print statement!
        print


#2

if char == 'A' or char == 'a':
print 'X', " "
else:
print char," "

Don't delete this print statement!
print

remove the " " from the print lines, and last print should not be in the for loop.


#3

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.