Here are some resources for more information about topics covered in this lesson:
Setting Up Python on Windows
00:00 In this video, you’ll learn how to set up Python on Windows. You’ll learn where to download Python, how to install Python, and how to open the Integrated Development and Learning Environment, also known as IDLE.
00:16 There are two ways to download Python on Windows. One is through the official Python distribution posted on the python.org website. The second is through the Windows App Store.
00:27 The Windows App Store version of Python is excellent for students and educational purposes, but it has some limitations that the python.org distribution doesn’t. In this course, you’ll download the official Python distribution from python.org.
00:42 Start by opening your preferred internet browser.
00:48 Then, navigate to python.org.
00:56 At the top of the website in the main navigation bar is a Downloads button. If you hover over it, you’ll see a button to download the latest version of Python for Windows.
01:07 At the time of this recording, that version is Python 3.9.5. Click on the button to download Python.
01:17 When Python finishes downloading, you can click the EXE file at the bottom of your browser or use File Explorer to navigate to the Downloads folder and open it from there.
On the first screen of the installer, you can see that you’re installing Python 3.9.5 or whichever version you downloaded. There’s an Install Now button, which will install Python as well as IDLE,
pip, and Python’s documentation.
There’s a Customize installation button you can use to choose the location of the install and select or de-select different features. There’s an option to install the launcher for all users, which is recommended and we’ll keep checked in this course, as well as an option to add Python 3.9 to
Let’s talk a little bit about what that means. Before we determine whether or not you should add Python to
PATH, let’s talk about what
PATH is an environment variable on Windows that tells the command line where to look for files and folders. Now, if you don’t know what an environment variable or the command line is, that’s fine.
The key takeaway is that
PATH tells the operating system where to look for things when you issue commands. Adding Python to your
PATH allows you to use the
python command in a terminal to run Python programs. Again, if this doesn’t make sense to you, that’s fine.
We’re not even going to use terminals in this course. So, should you add Python to
PATH? If you only have one version of Python installed, then you can safely add Python to
PATH in most cases.
If you need multiple versions of Python installed on the same computer, then it’s best to not add Python to
PATH. In either case, you can use the Python Launcher for Windows to run Python programs instead of the
In this course, we’ll be using the Integrated Development and Learning Environment, or IDLE, instead of the
python command. If you’d like more information on the Python Launcher for Windows, then check out the resources in the description of this video. In this course, it’s assumed that you’re installing Python for the first time and will only have one version of Python installed on your computer.
Even though we won’t be using the
python command in this course, it’ll be helpful to have it available later on, so you’ll see Python installed with the Add Python to PATH option selected.
03:42 Let’s get back to the installation. If you’re installing Python for the first time and only plan to have one version of Python installed, then go ahead and select Add Python 3.9 to PATH.
03:59 You’ll need to give your computer permission to make changes to your device, so go ahead and enter your user’s password.
04:12 On most computers, installing Python will take just a couple of minutes.
04:17 Once Python finishes installing, you’ll see a screen saying that Setup was successful. This screen includes links to the official online tutorial and the Python documentation, as well as an option to disable the path length limit.
Let’s pause for a moment and talk about what that is and whether or not you should disable it. So, what is this
MAX_PATH limitation and should you remove it? On older versions of Windows, file paths were limited to 260 characters.
The file path is a text representation of where a file or folder is located on Windows. It usually starts with
C: then a backslash and a list of folders containing the file. On the latest versions of Windows, the 260 character limit can be expanded to about 32,000 characters.
05:05 But you should only remove the limitation if you know for sure you’ll need it, because doing so will alter your computer’s configuration. In this course, it’s assumed you do not need to remove the limit, so we won’t be selecting that option. All right, let’s get back to the install.
05:21 Since we aren’t going to disable path length limit, we’ll go ahead and click the Close button. All right. So now you have Python installed, but how do you access it? In this course, we’ll be using Python’s Integrated Development and Learning Environment, IDLE, to interact with Python. There are two ways to open IDLE.
05:42 One is through the Start menu. The other is through the Windows search bar. To open IDLE from the Start menu, click on the Start menu icon and then scroll down until you find the Python 3.9 folder.
05:55 Since you just installed Python, you might be able to find IDLE in the Recently added section at the top of your Start menu, but let’s see where it’s located in case you don’t have that available.
06:10 Scroll until you find the Python 3.9 folder and click on it. Inside of the folder is an application called IDLE. Click on that to open IDLE.
06:24 This opens the IDLE shell. At the top of the window, you can see the version of Python running as well as some information about your operating system. Below that information are three red right angle brackets.
06:37 These are called a prompt. Whenever you see this, it means that Python’s waiting for you to give it some instructions. Now go ahead and close IDLE.
06:50 To open IDLE from the Windows search bar, start by typing idle into the search bar.
06:57 Under the Apps section, you’ll see an option for IDLE that says Python 3.9 64-bit. It might say 32-bit if you downloaded a 32-bit version of Python for your system.
07:10 Click on that to open IDLE. So, there you go! Now you know where to download Python, how to install it, and how to open Python’s Integrated Development and Learning Environment.
07:23 If you’d like to see how to install Python on other operating systems, feel free to watch the other lessons in this course.
Become a Member to join the conversation.