Executing Python Scripts on Mac using Python Launcher

Hans Mulder hansmu at xs4all.nl
Wed Jun 27 17:33:39 EDT 2012


On 27/06/12 22:45:47, David Thomas wrote:
> Thank you ever so much raw_input works fine.

> Do you think I should stick with Python 2 before I go to 3?

I think so.  The differences are not that big, but big
enough to confuse a beginner.  Once you know pyhton2,
read http://docs.python.org/py3k/whatsnew/3.0.html
That's the official overview of what has changed between
python2 and python3.

> I have a text book which is using 3 but I've been using an
> online tutorial which has been helping me lots, which uses
> version 2.

If you decide to use the book, you'll want to install Python3
on your Mac.  If you do that, you'll find that typing "python"
in Terminal still gets you python2.7; you have to type "pyhton3"
to get python3.

> I found by just typing python then having a space and
> dragging the file from finder into terminal works.

I just tried it, and it works.  Terminal uses backslashes
to protect characters that need quoting in the shell.  I'd
use single quotes myself, but this also works.

-- HansM




More information about the Python-list mailing list