Getting started 1. Introduction
Introduction
Python is a widely used, general-purpose programming language that is easy to learn, read, and write.
- Popular among researchers and developers for its simplicity and readability
- Used by major deep learning frameworks such as PyTorch
- Supported by an active open-source community and a large ecosystem of libraries
How Python works
Python is an interpreted language. Here is a simplified view of what happens when you run Python code:
- Your code saved as
.pyis interpreted into bytecode such as.pycfiles. - That bytecode is executed by a Python Virtual Machine.
- Most Python implementations such as CPython are written in C, which eventually runs as machine code.
Tools to run Python code
You can start with the Python interpreter, but many learners prefer tools with a friendlier interface.
VS Code
- Lightweight but powerful code editor
- Supports Python through extensions
- Includes terminal, linting, debugging, and version control tools
Google Colab
- Browser-based notebook environment
- No installation needed
- Comes with many common Python libraries
- Works well for quick experiments and teaching