Create a projects folder
Start by creating a single parent folder on your computer that will hold all your Python work. This keeps everything in one predictable place.1
Create your main projects folder
2
Create your first project folder
Inside
PythonProjects, create a folder for this course:Using lowercase letters and dashes (kebab-case) for folder names — like
python-for-ai — is a convention shared by most Python projects and GitHub repositories. It avoids issues with spaces in paths and feels natural when you start working with the terminal.Open the folder in VS Code
With your folder created, open it in VS Code using whichever method is most convenient: From VS Code:- Click File → Open Folder (or press
Ctrl/Cmd + O) - Navigate to your
python-for-aifolder and click Select Folder (Windows) or Open (macOS/Linux)
- Windows: Right-click the folder → Open with Code
- macOS: Drag the folder onto the VS Code dock icon
- Linux: Right-click the folder → Open with Code
Understanding the VS Code interface
Once the folder is open, take a moment to orient yourself:VS Code always operates on a folder, not just a file. This is why the Explorer panel shows your whole project tree. The editor uses this context to resolve imports, find related files, and understand your project layout.
Save as a workspace
A workspace file is a small bookmark that saves your project’s settings and lets you reopen everything with a single double-click.1
Save the workspace
With your folder open, click File → Save Workspace As…
2
Name and place the file
Save it inside the
python-for-ai folder and name it python-for-ai.code-workspace.3
Test it
Close VS Code completely, then double-click the
.code-workspace file in your file manager. VS Code should open directly to your project.- Which folders are part of your project
- Your project-specific editor settings (overriding global settings)
- Which files were open when you last closed the editor
- Your debugging configuration
Your project structure so far
After completing these steps, your folder looks like this:Your first Python file
Create and run your first Python program in this workspace.