Install Python on Windows
To install the python use the following steps –
- First of all download the python form http://www.python.org/download/ for windows operating system and according to your system requirements.
- Once you have downloaded the Python MSI navigate to the download location on your computer, double clicking the file and click on run button.
- Select whether to install python for all users or not. If you want to install python for only your account then select second option otherwise select first option.
- If you want to change the location then select the folder where you want to install it otherwise click on next.
- Add python.exe to path
It will install python on your system in command line mode while Python downloads and installs “Pip.” It is a package management tool which allows you to install all the additional Python packages which are available for download through https://pypi.python.org/pypi
To include the Python directory to the path use the following command in windows:-
Right click on My Computer ->Properties ->Advanced System setting ->Environment Variable ->Select Path->Edit
Then it will open a box in which you add the path where the java is installed by using ; (semi colon).
If it contains ‘C:\Windows\System32′ then change your path like as follows: ‘C:\Windows\System32; C:\Program Files\python\bin’.
Install Python on Linux/Unix-
To install python on linux/unix use the following steps –
- First of all download the python form http://www.python.org/download/ for linux/unix operating system and according to your system requirements.
- Download the zipped source code and then extract the files.
- If you want to modify some options then edit theModules/Setup
- Run ./configure script
Python is installed in a standard location i.e. /usr/local/bin and its libraries at/usr/local/lib/python_version.
To include the Python directory to the path use the following command in Linux/Unix:
- export PATH=”$PATH:/usr/local/bin/python_version” in bash shell
- PATH=”$PATH:/usr/local/bin/python_version” in sh shell
This blog will help you get a better understanding of Automate Your Coding with Python!