
40 Introduction to Computational Mo de ls with Python
Figure 2.3 General structure o f a Python progr am.
4. Definition of classes. This is another optional component in a Python
program. A class definition allows the program to create objects of that
class. When present, one or mor e classes are defined in this part of the
program.
5. The instructions are Python statements that invoke or call the functions
in the program and/or in the imported modules. These instructions can
also create and manipulate objects using the class definitions in the
program and/or in the imported modules.
Function definitions can be programmer-defined functions that are invoked ...