Skip to Main Content
C++ Programming: Visual QuickStart Guide
book

C++ Programming: Visual QuickStart Guide

by Larry Ullman, Andreas Signer
December 2005
Beginner content levelBeginner
528 pages
14h 13m
English
Peachpit Press
Content preview from C++ Programming: Visual QuickStart Guide

7. Introducing Objects

Programming with objects is at the heart of C++ and gives it advantages over C and many other languages. In case you are apprehensive about this novel way to approach your programs, it should be made clear that objects are just a new data type, with nearly unlimited potential. You start by defining a class, a formal model of what something should do, and then you can create an instance of that class, which is the object itself. This is somewhat like how structures work (see Chapter 6, “Complex Data Types”) but more potent. For starters, an object can have within it both variables and functions, whereas structures are typically only made up of other variables.

The first thing you’ll need to know is how to write a simple ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

C Programming: Visual Quickstart Guide

C Programming: Visual Quickstart Guide

Larry Ullman, Marc Liyanage

Publisher Resources

ISBN: 032135656XPurchase book