McGraw-Hill OnlineMcGraw-Hill Higher EducationLearning Center
Student Center | Instructor Center | Information Center | Home
Workbook
EzWindows Software Packages
Chapter Objectives
Chapter Outline
Chapter Overview
Lab
Self-Check Solutions
Feedback
Help Center


Cohoon/Davidson: C++ Program Design, Third Edition
C++ Program Design, 3/e
James P. Cohoon, University of Virginia
Jack W. Davidson, University of Virginia

Modifying objects

Chapter 3 Overview

In this chapter, we introduce operators that can modify objects and the use of programmer-defined object types. The operators are the assignment operators and the extraction operator. Of particular importance is =, the assignment operator. The assignment operation is common to most programming languages, and understanding the concept of assignment and its implementation in a language is a key concept that all programmers must master. The extraction operator >> modifies an object by extracting a value from a stream and storing that value in an object. The chapter concludes by introducing two programmer-defined object types: SimpleWindow and RectangleShape. We show how to define and manipulate instances of these programmer-defined object types by writing programs that produce graphical displays.