Discussion:
[Tutor] Invalid Syntax Message
Shannon Rodenbeck
2015-09-14 21:50:15 UTC
Permalink
I have downloaded Python 3.4.3 on my Mac 10.10.4. When i try running my
programs from IDLE to go on Shell i get the message that says "Invalid
Syntax". I've tried my programs on a different windows computer and it runs
and works perfectly. How do I fix this problem so the programs are able to
run on my Mac.


Thank you,
Shannon Rodenbeck
***@saintmarys.edu
_______________________________________________
Tutor maillist - ***@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor
Emile van Sebille
2015-09-14 23:07:38 UTC
Permalink
Post by Shannon Rodenbeck
I have downloaded Python 3.4.3 on my Mac 10.10.4. When i try running my
programs from IDLE to go on Shell i get the message that says "Invalid
Syntax". I've tried my programs on a different windows computer and it runs
and works perfectly. How do I fix this problem so the programs are able to
run on my Mac.
Start by providing a complete copy-n-paste of the screen when the error
occurs. That normally provides enough detail to diagnose the issue.

Emile



_______________________________________________
Tutor maillist - ***@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor
Alan Gauld
2015-09-14 23:38:42 UTC
Permalink
Post by Shannon Rodenbeck
I have downloaded Python 3.4.3 on my Mac 10.10.4. When i try running my
programs from IDLE to go on Shell i get the message that says "Invalid
Syntax". I've tried my programs on a different windows computer and it runs
and works perfectly. How do I fix this problem so the programs are able to
run on my Mac.
Are you absolutely sure the two machines are running the same
python versions? Try this on both:

import sys
print(sys.version)

In particular make sure that the IDLE version matches the
interpreter version you expect.

If its all OK then show us the actual code and actual
error message (all of it).

One final thing to try is running your code on the Mac under the
Terminal app:

$ python3 yourscript.py

See if that works differently.
--
Alan G
Author of the Learn to Program web site
http://www.alan-g.me.uk/
http://www.amazon.com/author/alan_gauld
Follow my photo-blog on Flickr at:
http://www.flickr.com/photos/alangauldphotos


_______________________________________________
Tutor maillist - ***@python.org
To unsubscribe or change subscription options:
https://mail.python.org/mailman/listinfo/tutor
Loading...