wierd error after if or while

ben at co.and.co ben at co.and.co
Tue May 9 08:58:26 EDT 2000


nick_knight at my-deja.com wrote:
> I am a newbie - in fact I just downloaded it today, and so far it looks
> like a very useful language. The only problem is I seem to be doing
> something stupid. If I run the folloing bit of code
> 
> x = 4
> 
> if x==4:
> print "hello"
> 
> I get the following error message
> 
>   File "<stdin>", line 2
>     print "hello",
>         ^
> 
> This seems perfectly legal to me - am I missing something or has the
> install gone wrong perhaps.

Read the tutorial:
http://www.python.org/doc/current/tut/node5.html

Scroll down till "3.2. First Steps Towards Programming"

Read the paragraph at the third bullet, and start screaming and cursing 
for 5 minutes. Afterwards, you'll be perfectly happy for the rest of
your python-programming life.

Greetings,
-- 
ben . de . rydt at pandora . be ------------------ your comments
http://users.pandora.be/bdr/ ------- inl. IPv6, Linux en Pandora




More information about the Python-list mailing list