Trying to install Swampy for Python.

885 Views Asked by At

So I'm following the 'Think Python' PDF guide and this is my first real hurdle. I tried to follow a guide to install it but it's completely over my head. I know this is vague but if anyone could guide me through it like I'm a pensioner I'd be grateful.

I'm currently using Python 2.7.6. I think I downloaded setup tools and PIP but I can't be too sure.

Sorry for the openness and vagueness of this question but I'm quite stuck.

2

There are 2 best solutions below

8
On BEST ANSWER

Edit: Since you're on Windows, I suggest you download and run this installer for Pip.

Once that's done, if you've downloaded and installed Pip correctly, all you should have to do is open a terminal, type pip install swampy, and press return.

In order to test if you've installed Swampy correctly, do the following:

  1. Open a command prompt.
  2. Type python and press return
  3. Type from TurtleWorld import * and press return.

If you've installed Swampy correctly, you shouldn't see any error messages. If you see something like this ImportError: No module named TurtleWorld, Swampy isn't installed correctly yet.

References:

0
On
  1. Download Swampy package tar.gz, extract it:

    $ tar -zxvf [swampy-package-name]

  2. cd to Swampy folder, in command line, you type:

    $ sudo python setup.py install

  3. run python

    $ python

    from Swampy.TurtleWorld import *

    • or run follow example of think python

      $ python polygon.py

It work by python. some other python version doesn't work.