官术网_书友最值得收藏!

Installing Python

For this book, we suggest using Python 2.7; this version of Python is fully compatible with the libraries and packages that we will use in the examples and also has precompiled binary files available on the Internet for Windows users. We will keep all the examples as compatible as possible with Python 3.4 so that it would be easy to port future upgrades.

Windows users may find compatibility problems with the 64-bit packages, so we recommend the 32-bit version of Python for them.

For Linux users, we will show the installation procedures for Ubuntu Linux distribution and use package managers, so you don't need to worry about versions and requirements; the package managers will do this for you.

The libraries that you will install are written in Python and other languages, the most common being C and C++. These libraries can abstract classes, methods, and functions to Python objects or have an extra layer that makes the connection; when this happens, we say that the library has Python bindings.

Windows

Here are the steps to perform for the installation of Python on Windows:

  1. Go to https://www.python.org/downloads/windows/ and click on Download the latest Python 2.7 release for Windows.
  2. On the next page, roll down, and you will find a list of files; make sure that you download Windows x86 MSI installer.
  3. After the file is downloaded, open the installer by clicking on the file and following the instructions. Proceed with the default options by clicking on the Next button.

Ubuntu Linux

Ubuntu already comes with Python installed, so there is no need to install it. If for any reason, it's not available, you can install it with the following command:

sudo apt-get install python

Python 2.7.9 comes with Pip, but if you use an older version, you need to install Pip with the following command:

sudo apt-get install python-pip
主站蜘蛛池模板: 长葛市| 嘉义县| 宝山区| 桓仁| 巴彦县| 海宁市| 左贡县| 台南县| 博罗县| 宾阳县| 临朐县| 海城市| 大同县| 洪雅县| 岐山县| 邵武市| 富川| 宿松县| 昭平县| 闻喜县| 资中县| 六盘水市| 建瓯市| 电白县| 措勤县| 于田县| 商都县| 洞口县| 师宗县| 民勤县| 太和县| 中方县| 潼南县| 隆昌县| 蒙山县| 丁青县| 闵行区| 栖霞市| 舒城县| 兴城市| 乌兰察布市|