Python installation
Installing python
Installation on linux
Most modern Linux distributions include Python by default. To verify your version:
python3 --versionIf it is not installed, you can install it using your package manager:
sudo apt update
sudo apt install python3 python3-pipInstallation on windows
Go to the official Python website: https://www.python.org/downloads Download the latest Windows installer.
Run the installer and make sure to check the option Add Python to PATH.
After installation, verify it by opening a terminal (cmd or PowerShell):
python --versionYou can also install packages using pip:
pip install package_nameInstalling Jupyter Notebook
What is Jupyter
Jupyter Notebook is an interactive environment that allows you to combine live code, visualizations, and text in a single document. It is especially useful for data analysis, machine learning, and education.
Installation
Once Python and pip are installed, you can install Jupyter using:
pip install jupyterlabTo start it:
jupyter labThis will open a web interface in your browser where you can write and execute Python code interactively.
When to use command line or Jupyter
Using the command line
- Running scripts directly (python script.py)
- Automating tasks and system operations
- Working with projects that require performance or command-based workflows
- Integrating with development tools like Git or Docker
- Faster execution for scripts
- Easier integration with automation
- Lower resource usage
Using Jupyter
- Data exploration and visualization
- Prototyping and experimentation
- Teaching and sharing results interactively
- Interactive code execution
- Easy visualization of data
- Supports text, math, and graphics in one notebook