Skip to content

Development Environment Setup

Video Lecture

Development Environment Setup Development Environment Setup Development Environment Setup


The most universal approach to installing Python is to visit the official Python download page at,

Normally this page will detect your operating system from the useragent in your browser and select which install is appropriate for you.

There will be 64 and 32 bit versions for your operating system. At the time of writing this documentation, the option of downloading the 64bit version was the most common, and the version was 3.9.x.

The code in this documentation will be using a simplified generic style of Python that should work in all versions since Python version 3.

To test if you already have python on your system, depending on your operating system, whether Windows, Linux or Mac OSX, open a terminal/bash/cmd or PowerShell prompt.

and type

python -V

Note the capital V in the above command.

Sometimes python is named as python3

So you can also try

python3 -V

You are looking for a response that indicates you have Python 3 or above installed. Not an error, or Python 2.x

On my windows workstation, if I use PowerShell, the response is

PS> python -V
Python 3.9.2

I have Python3 already installed using the official python link from above.

If you are using a recent version of Linux or Mac OSX, then the command to check for the Python version on your system is most likely to be,

python3 -V

Remember to follow the official install instructions for your operating system at

Course Code

All the code examples in this documentation can be viewed from my GitHub repository at

If you have Git installed, you can download a copy locally using the command

git clone

or you can download a zip of all the code, by visiting this link in your browser

or using wget on Linux

sudo apt install unzip
cd Design-Patterns-In-Python/

You can then experiment with the code at your own pace and try out different variations.

If you would rather type the code from the documentation, then follow these further recommendations.

On my system, I have created a working folder on one of my spare drives, E:\, and then created a new folder in it named python_design_patterns, and then cd into it. You can use a different folder name if you prefer.

PS C:\> e:
PS E:\> mkdir python_design_patterns
PS E:\> cd .\python_design_patterns

Each section will be in a new folder named after the design pattern section.

I.e,. The code that I write for the Factory pattern will be in its own subfolder named factory

PS E:\python_design_patterns> mkdir factory
PS E:\python_design_patterns> cd .\factory
PS E:\python_design_patterns\factory> 


If you are working on Windows, then I recommend to also install VSCode to use as your IDE when learning Python.

This is optional and you may prefer to use Notepad or any other popular IDE that you can download or use online that will also assist you when writing Python.

You can download VSCode from

You can then open VSCode from your current working folder by typing code .

PS E:\python_design_patterns> code .

And VSCode will open ready for you in your working folder where you can use it to add new files or folders as needed.

Open VSCode