O'Reilly logo

Hello! Python by Anthony Briggs

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 6. Classes and object-oriented programming

 

This chapter covers
  • An easier way to think about classes
  • How to use classes to design your programs

 

Until now, we’ve been skimming over one of the fundamental ways you can organize your program in Python: the class. Classes and object-oriented programming are normally seen as big, scary things that real programmers use to write their programs, and you might think you need a lot of theoretical knowledge in order to use them properly. Nothing could be further from the truth. In Python, it’s possible to ease into classes and object-oriented programming.

In this chapter, you’ll start with the code you wrote back in chapter 2 to generate caves for Hunt the Wumpus and then see how much easier ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required