squirreltown
Posts: 10
Joined: Mon Jan 23, 2017 2:08 am

python IDLE/jessie

Fri Mar 03, 2017 5:56 pm

If i make a file in python IDLE 3.4.2 and run it

Code: Select all

name='Red'
if len(name) == 4:
    print('oops!')
else:
    print(name)
it works fine.
Typing the same thing into the shell gets a syntax error - multiple statements found while compiling a single statement.

??

ghp
Posts: 1516
Joined: Wed Jun 12, 2013 12:41 pm
Location: Stuttgart Germany
Contact: Website

Re: python IDLE/jessie

Sat Mar 04, 2017 6:57 am

Hello,
I looked around and found some hints on the web: seems to be that you can only copy-and-paste line-by-line into the Shell window, not a complete code fragment at a time.
Regards,
Gerhard

squirreltown
Posts: 10
Joined: Mon Jan 23, 2017 2:08 am

Re: python IDLE/jessie

Sat Mar 04, 2017 8:06 pm

Thank you. Appreciate the reply.

Return to “Python”