What did I do wrong?


#1

I think I have a big problem with my brain or my eyes ...
please help me....

original = raw_input("Enter a word:")
print original
if len(original) > 0:
print original
else:
print "empty"

(it says "IndentationError: unexpected indent")


#2

your code should be like that

if len(original) > 0:
    print original
else:
    print "empty"

#3

But if I look at mine, (not hear, in the code) it looks like that
if len(original) > 0:
print original
else:
print "empty"

(my code has the them placed well, I don't know why in hear they don't)


#4

It's ok, I did it.
Thank you


#5

Have you tried indenting the print statements under the if and else statements 4 spaces? The computer could be outputting 'unexpected indent' because it is confused when indents aren't in the right place, like under the if and else statements.

if len(original) > 0:
print original
else:
print "empty"


#6

Thanks (but I already moved on)


#7

original = raw_input("Enter a word:")
print original
if len(original) > 0
print original
else:
print "empty"

error: did you create a variable called original?

Please help


#8

You need to put : at the ned of the if (after 0)