Sitemap

Member-only story

Using the Python Interpreter (REPL)

6 min readJun 7, 2024

--

In this short article, we’ll introduce the Python interpreter (REPL) and explore it’s common use cases. A free companion video is available on YouTube:

The Python Interpreter is an extremely useful tool for performing calculations, investigating code behavior, viewing documentation, and can even help with debugging.

The python interpreter will read your input, evaluate the code, display the results, and then wait for your next input. This read-evaluate-print-loop is commonly referred to as REPL. Note that REPL is a general programming concept that is used with many programming languages. For Python, we tend to just refer to it as the interactive Python interpreter.

To experience the magnificent glory of the python interpreter, we first need to call it by name. We can access the interpreter by opening a terminal and typing the “python” command.

Note that you might need to use the command “python3” depending on your operating system.

Press enter or click to view image in full size
Opening the Python Interpreter on Ubuntu

Notice that the python interpreter is indicated by “>>>” (three arrows). You can expect…

--

--

KNuggies
KNuggies

Written by KNuggies

Creating education content for programming in C++, Python, and other languages.