1.7. Review of Basic Python¶
In this section, we will review the programming language Python and also provide some more detailed examples of the ideas from the previous section. If you are new to Python or find that you need more information about any of the topics presented, we recommend that you consult a resource such as “The Python Language Reference”, “The Python Tutorial”, or other documents available at https://docs.python.org/. Our goal here is to reacquaint you with the language and also reinforce some of the concepts that will be central to later chapters.
Python is a modern, easy-to-learn, object-oriented programming language.
It has a powerful set of built-in data types and easy-to-use control
constructs. Since Python is an interpreted language, it is most easily
reviewed by simply looking at and describing interactive sessions. You
should recall that the interpreter displays the familiar >>>
prompt
and then evaluates the Python construct that you provide. For example,
>>> print("Algorithms and Data Structures")
Algorithms and Data Structures
shows the prompt, the print
function, the result, and the next
prompt.