Object-Oriented Programming in C++
This user-friendly best-seller is the easiest way to learn OOP with the C++ programming language. Suitable for professional programmers, students, and kitchen-table enthusiasts.
  • Includes examples like: ELEV, VERYLONG, and PIPES
  • Covers the features of the C++ programming language including templates and exceptions
  • Fully compatible with Borland C++ 4.5 compilers
1122977352
Object-Oriented Programming in C++
This user-friendly best-seller is the easiest way to learn OOP with the C++ programming language. Suitable for professional programmers, students, and kitchen-table enthusiasts.
  • Includes examples like: ELEV, VERYLONG, and PIPES
  • Covers the features of the C++ programming language including templates and exceptions
  • Fully compatible with Borland C++ 4.5 compilers
57.99 In Stock
Object-Oriented Programming in C++

Object-Oriented Programming in C++

by Robert Lafore
Object-Oriented Programming in C++

Object-Oriented Programming in C++

by Robert Lafore

eBook

$57.99 

Available on Compatible NOOK devices, the free NOOK App and in My Digital Library.
WANT A NOOK?  Explore Now

Related collections and offers


Overview

This user-friendly best-seller is the easiest way to learn OOP with the C++ programming language. Suitable for professional programmers, students, and kitchen-table enthusiasts.
  • Includes examples like: ELEV, VERYLONG, and PIPES
  • Covers the features of the C++ programming language including templates and exceptions
  • Fully compatible with Borland C++ 4.5 compilers

Product Details

ISBN-13: 9780132714297
Publisher: Pearson Education
Publication date: 12/18/1997
Series: Kaleidoscope
Sold by: Barnes & Noble
Format: eBook
Pages: 1040
File size: 10 MB
Age Range: 18 Years

About the Author

Robert Lafore has been writing books about computer programming since 1982. His best- selling titles include Assembly Language Programming for the IBM PC, C Programming Using Turbo C++, C++ Interactive Course, and Data Structures and Algorithms in Java. Mr. Lafore holds degrees in mathematics and electrical engineering, and has been active in programming since the days of the PDP-5, when 4K of main memory was considered luxurious. His interests include hiking, windsurfing, and recreational mathematics.

Table of Contents

Introduction1
1The Big Picture9
Why Do We Need Object-Oriented Programming?10
Characteristics of Object-Oriented Languages16
C++ and C22
Laying the Groundwork23
The Unified Modeling Language (UML)23
Summary25
Questions25
2C++ Programming Basics29
Getting Started30
Basic Program Construction30
Output Using cout33
Directives35
Comments36
Integer Variables38
Character Variables42
Input with cin45
Floating Point Types48
Type bool51
The setw Manipulator52
Variable Type Summary54
Type Conversion56
Arithmetic Operators60
Library Functions65
Summary68
Questions69
Exercises71
3Loops and Decisions75
Relational Operators76
Loops78
Decisions93
Logical Operators114
Precedence Summary118
Other Control Statements118
Summary123
Questions124
Exercises126
4Structures131
Structures132
Enumerations148
Summary156
Questions156
Exercises158
5Functions161
Simple Functions162
Passing Arguments to Functions167
Returning Values from Functions176
Reference Arguments182
Overloaded Functions188
Recursion193
Inline Functions195
Default Arguments197
Scope and Storage Class199
Returning by Reference206
const Function Arguments208
Summary209
Questions210
Exercises212
6Objects and Classes215
A Simple Class216
C++ Objects as Physical Objects223
C++ Objects as Data Types226
Constructors227
Objects as Function Arguments233
The Default Copy Constructor238
Returning Objects from Functions240
A Card-Game Example243
Structures and Classes247
Classes, Objects, and Memory247
Static Class Data249
const and Classes252
What Does It All Mean?256
Summary257
Questions257
Exercises259
7Arrays and Strings263
Array Fundamentals264
Arrays as Class Member Data279
Arrays of Objects283
C-Strings290
The Standard C++ string Class302
Summary310
Questions311
Exercises313
8Operator Overloading319
Overloading Unary Operators320
Overloading Binary Operators328
Data Conversion344
UML Class Diagrams357
Pitfalls of Operator Overloading and Conversion358
Keywords explicit and mutable360
Summary364
Questions364
Exercises367
9Inheritance371
Derived Class and Base Class373
Derived Class Constructors380
Overriding Member Functions382
Which Function Is Used?383
Inheritance in the English Distance Class384
Class Hierarchies388
Inheritance and Graphics Shapes393
Public and Private Inheritance396
Levels of Inheritance399
Multiple Inheritance403
private Derivation in Empmult409
Ambiguity in Multiple Inheritance413
Aggregation: Classes Within Classes414
Inheritance and Program Development420
Summary421
Questions422
Exercises424
10Pointers429
Addresses and Pointers430
The Address-of Operator &431
Pointers and Arrays440
Pointers and Functions443
Pointers and C-Type Strings452
Memory Management: new and delete458
Pointers to Objects464
A Linked List Example469
Pointers to Pointers474
A Parsing Example479
Simulation: A Horse Race484
UML State Diagrams490
Debugging Pointers492
Summary493
Questions494
Exercises497
11Virtual Functions503
Virtual Functions504
Friend Functions520
Static Functions529
Assignment and Copy Initialization532
The this Pointer547
Dynamic Type Information553
Summary557
Questions558
Exercises561
12Streams and Files567
Stream Classes568
Stream Errors577
Disk File I/O with Streams583
File Pointers597
Error Handling in File I/O601
File I/O with Member Functions604
Overloading the Extraction and Insertion Operators616
Memory as a Stream Object620
Command-Line Arguments622
Printer Output624
Summary626
Questions627
Exercises628
13Multifile Programs633
Reasons for Multifile Programs634
Creating a Multifile Program637
Inter-File Communication638
A Very Long Number Class651
A High-Rise Elevator Simulation658
Summary676
Questions677
Projects679
14Templates and Exceptions681
Function Templates682
Class Templates690
Exceptions703
Summary720
Questions720
Exercises722
15The Standard Template Library725
Introduction to the STL726
Algorithms735
Sequence Containers743
Iterators751
Specialized Iterators763
Associative Containers771
Storing User-Defined Objects778
Function Objects786
Summary794
Questions795
Exercises797
16Object-Oriented Software Development801
Evolution of the Software Development Processes802
Use Case Modeling805
The Programming Problem809
The Elaboration Phase for the Landlord Program812
From Use Cases to Classes816
Writing the Code824
Interacting with the Program841
Final Thoughts843
Summary844
Questions844
Projects846
AASCII Chart849
BC++ Precedence Table and Keywords859
Precedence Table860
Keywords860
CMicrosoft Visual C++863
Screen Elements864
Single-File Programs864
Multifile Programs866
Building Console Graphics Lite Programs868
Debugging868
DBorland C++Builder871
Running the Example Programs in C++Builder872
Cleaning Up the Screen873
Creating a New Project873
Naming and Saving a Project874
Starting with Existing Files875
Compiling, Linking, and Executing875
Adding a Header File to Your Project876
Projects with Multiple Source Files877
Console Graphics Lite Programs878
Debugging878
EConsole Graphics Lite881
Using the Console Graphics Lite Routines882
The Console Graphics Lite Functions883
Implementations of the Console Graphics Lite Functions884
Source Code Listings885
FSTL Algorithms and Member Functions895
Algorithms896
Member Functions907
Iterators909
GAnswers to Questions and Exercises913
Chapter 1914
Chapter 2914
Chapter 3917
Chapter 4921
Chapter 5924
Chapter 6928
Chapter 7932
Chapter 8937
Chapter 9943
Chapter 10949
Chapter 11954
Chapter 12960
Chapter 13963
Chapter 14964
Chapter 15969
Chapter 16974
HBibliography977
Advanced C++978
Defining Documents978
The Unified Modeling Language978
The History of C++979
Other Topics979
Index981
From the B&N Reads Blog

Customer Reviews