Chapter four introduces concepts from Object-Oriented Programming (OOP). The chapter describes what an object is and how objects are used in Python programming. Objects are so integral to Python that readers are actually introduced to OOP starting in the first chapter, but chapter four is more intentional about understanding the OOP paradigm.

The chapter introduces OOP to the reader by introducing turtle graphics programming. Learning turtle graphics is both fun and challenging with instant feedback available from the graphics that the reader programs. OOP is further emphasized by learning to read XML files. XML files are formatted data files with a structure that can be parsed using an XML parser. Readers learn what a parser is and how to use it to parse XML files.

Finally, XML processing and turtle graphics are combined to plot exercise data captured from an exercise computer, tying the use of OOP in XML processing and graphics programming together. In addition, dictionary objects in Python are also introduced as the last built-in data type covered in the text.


Maximum Heart Rate Accessor Method Practice Problem Workout Data Mutator Method 
These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.


  1. 2.
    David Flanagan and Yukihiro Matsumoto. The ruby programming language. O’Reilly, Sebastopol, CA, 2008. Google Scholar
  2. 6.
    Robin Milner. A theory of type polymorphism in programming. Journal of Computer and System Sciences, 17:348–375, 1978. MathSciNetzbMATHCrossRefGoogle Scholar
  3. 10.
    Guido van Rossum. Guido’s personal home page, 2010. [Online; accessed 1/29/2010;].
  4. 14.
    Wikipedia. Logo (programming language), 2010. [Online; accessed 1/29/2010;].

Copyright information

© Springer-Verlag London Limited 2011

Authors and Affiliations

  1. 1.Dept. Computer ScienceLuther CollegeDecorahUSA

Personalised recommendations