1.3. Programs and Processes¶
A program is any software application that you can run, such as a web browser, spreadsheet application, or word processor. A process is a running instance of a program. For example, Figure below shows five running processes of the same calculator program.
Processes remain separate from each other, even when running the same program. For example, if you ran several instances of a Python program at the same time, each process might have separate variable values. Every process, even processes running the same program, has its own cwd and environment variable settings. Generally speaking, a command line will run only one process at a time (although you can have multiple command lines open simultaneously).
Each operating system has a way of viewing a list of running processes.
On Windows, you can press CTRL-SHIFT-ESC
to bring up the Task
Manager application. On macOS, you can run
ApplicationsUtilitiesActivity
Monitor. On Ubuntu Linux, you can
press CTRL-ALT-DEL
to open an application also called the Task
Manager. These task managers can force a running process to terminate if
it’s unresponsive.