O'Reilly logo

C++ All-in-One For Dummies, 3rd Edition by John Paul Mueller, Jeff Cogswell

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 1

Planning and Building Objects

In This Chapter

arrow Recognizing objects so that you can create classes

arrow Encapsulating classes into self-contained capsules

arrow Building hierarchies of classes through inheritance

arrow Discovering classes

Step outside for a moment and look down. What is the thing you are standing on? (Hint: It’s giant, it’s made of rock and sand and stone and molten lava, and it’s covered with oceans and land.) The answer? A thing! (Even a planet is a thing.) And now go back inside. What’s the thing that you opened — the thing with a doorknob? It’s a thing, too! It’s a slightly different kind of thing, but a thing nevertheless. And what are you inside? Okay, you get the idea. Everything you can imagine is a thing — or, to use another term, an object. Remember that word: object.

Over the years, researchers in the world of computer programming (now, doesn’t that sound like an exciting job?) have figured out that the best way to program computers is to divide whatever it is you’re trying to model into a bunch of objects. These objects have capabilities and characteristics. ...

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