Installing Python on Windows
How to install python on Windows…
- Download the latest version of Python for Windows. Check the box for Add Python to Path.
- You can run Python commands one line at a time in the Command Prompt window or in the Python IDLE (Integrated Development and Learning Environment) Shell. To run scripts, use the IDLE Editor.
- To code in the Command Prompt window:
- In Command Prompt, launch the Python interpreter by typing py and press Enter.
- Type print('Hello world!') and press Enter.
- You should see:Hello world!
- To code in Python IDLE:
- Type IDLE in the Windows search bar.
- IDLE launches the Shell window.
- To switch to the Editor, open a new file (File --> New File).
- Type a simple script e.g.
- Save the file in a local folder (File --> Save As)
- Run the script (Run --> Run Module)
- You should see:
- Type your response and press Enter.
Enter your favorite movie: