You are new to computer programming or you are new to python programming. That is why you are here. This post will guide you through how to set up your machine to be able to run python programs. As you may have already read somewhere, python is an interpreted, high level, general purpose programming language. We are going to guide you through how to set up python for windows environment. Note that at the time of writing this, the latest version of python is 3.9.4. You can use whatever version you need to, but if there is no specific reason to install an older version of python, just follow the steps along without thinking much about the versions. You can also have multiple python versions installed on your computer in different virtual environments. However the topic of virtual environments is beyond the scope of this tutorial.
Windows
- open you prefered browser and go to this address: python.org/ftp/python/3.9.4/python-3.9.4-am..
This link is going to directly download an excecutable file into your file system.
open the excecutable file and install it.
You will see a checkbox with the description
Add python to PATH
ensure that it is selected before you install it so that you can access your python installation from the command line. - To test your python installation, fire up the command prompt and type
python --version
The expected output is
python 3.9.4
If there is this error,
python is not recognized as an internal or external command,operable program or batch file.
,you will need to go through the steps again to check if there is a step you skipped. If there is still an error, reach out to me for guidance through this.
Ubuntu