9780201889543

The C++ Programming Language

by
  • ISBN13:

    9780201889543

  • ISBN10:

    0201889544

  • Edition: 3rd
  • Format: Paperback
  • Copyright: 1997-06-20
  • Publisher: Addison-Wesley Professional
  • View Upgraded Edition

Note: Supplemental materials are not guaranteed with Rental or Used book purchases.

Purchase Benefits

  • Free Shipping Icon Free Shipping On Orders Over $35!
    Your order must be $35 or more to qualify for free economy shipping. Bulk sales, PO's, Marketplace items, eBooks and apparel do not qualify for this offer.
  • eCampus.com Logo Get Rewarded for Ordering Your Textbooks! Enroll Now
List Price: $79.99 Save up to $22.40
  • Buy Used
    $57.59
    Add to Cart Free Shipping Icon Free Shipping

    USUALLY SHIPS IN 24-48 HOURS

Supplemental Materials

What is included with this book?

Summary

The C++ Programming Language, Third Edition

Bjarne Stroustrup


Preface


Programming is understanding.
- Kristen Nygaard

I find using C++ more enjoyable than ever. C++'s support for design and programming has improved dramatically over the years, and lots of new helpful techniques have been developed for its use. However, C++ is not just fun. Ordinary practical programmers have achieved significant improvements in productivity, maintainability, flexibility, and quality in projects of just about any kind and scale. By now, C++ has fulfilled most of the hopes I originally had for it, and also succeeded at tasks I hadn't even dreamt of.

This book introduces standard C++* and the key programming and design techniques supported by C++. Standard C++ is a far more powerful and polished language than the version of C++ introduced by the first edition of this book. New language features such as name spaces, exceptions, templates, and run-time type identification allow many techniques to be applied more directly than was possible before, and the standard library allows the programmer to start from a much higher level than the bare language.

About a third of the information in the second edition of this book came from the first. This third edition is the result of a rewrite of even larger magnitude. It offers something to even the most experienced C++ programmer; at the same time, this book is easier for the novice to approach that its predecessors were. The explosion of C++ use and the massive amount of experience accumulated as a result makes this possible.

The definition of an extensive standard library makes a difference to the way C++ concepts can be presented. As before, this book presents C++ independently of any particular implementation, and as before, the tutorial chapters present language constructs and concepts in a "bottom up" order so that a construct is used only after it has been defined. However, it is much easier to use a well-designed library than it is to understand the details of its implementation. Therefore the standard library can be used to provide realistic and interesting examples well before a reader can be assumed to understand its inner workings. the standard library itself is also a fertile source of programming examples and design techniques.

This book presents every major C++ language feature and the standard library. It is organized around language and library facilities. However, features are presented in the context of their use. That is, the focus is on the language as the tool for design and programming rather than on the language in itself. This book demonstrates key techniques that make C++ effective and teaches the fundamental concepts necessary for mastery. Except where illustrating technicalities, examples are taken from the domain of systems software. A companion, The Annotated C++ Language Standard, presents the complete language definition together with annotations to make it more comprehensible.

The primary aim of this book is to help the reader understand how the facilities offered by C++ support key programming techniques. The aim is to take the reader far beyond the point where he or she gets code running primarily by copying examples and emulation programming styles from other languages. Only a good understanding of the ideas behind the language facilities leads to mastery. Supplemented by implementation documentation, the information provided is sufficient for completing significant real-world projects. The hope is that this book will help the reader gain new insights and become a better programmer and designer.

Acknowledgements
In addition to the people mentioned in the acknowledgment section of the first and second editions, I would like to thank Matt Austern, Hans Boehm, Don Caldwell, Lawrence Crowl, Alan Feuer, Andrew Forrest, Tim Griffin, Peter Juhl, Brian Kernighan, Andrew Koenig, Mike Mowbray, Rob Murray, Lee Nackman, Joseph Newcomer, Alex Stepanov, David Vandevoorde, Peter Weinberger, and Chris Van Wyk for commenting on draft chapters of this third edition.

I would also like to thank the volunteers on the C++ standards committees who did an immense amount of constructive work to make C++ what it is today. It is slightly unfair to single out individuals, but it would be even more unfair not to mention anyone, so I'd like to especially mention Mike Ball, Dag Brück, Sean Corfield, Ted Goldstein, Kim Knutilla, Andrew Koenig, Josée Lajoie, Dmitry Lenkov, Nathan Myers, Martin O'Riordan, Tom Plum, Jonathan Shopiro, John Spicer, Jerry Schwarz, Alex Stepanov, and Mike Vilot, as people who each directly cooperated with me over some part of C++ and its standard library.

Bjarne Stroustrup
Murray Hill, New Jersey


*At the time of writing, the C++ Standard is still only a "Final Committee Draft Standard." However, no significant changes to the language or the standard library are anticipated.



0201889544P04062001

Author Biography

Bjarne Stroustrup is the designer and original implementer of C++ and the author of The C++ Programming Language (first edition 1985, second edition 1991, third edition 1997), The Design and Evolution of C++ (1994), and Programming: Principles and Practice using C++ (2010). He is the College of Engineering Chair in Computer Science Distinguished Professor at Texas A&M University, a member of the National Academy of Engineering, and an AT&T Fellow. Before moving to academia, he worked for decades in AT&T Bell Labs. He is a founding member of the ISO C++ standards committee. Vist him on the web at www.research.att.com/~bs/.

Table of Contents

Preface v(2)
Preface to Second Edition vii(2)
Preface to First Edition ix
Introductory Material 1(2)
1 Notes to the Reader
3(18)
2 A Tour of C++
21(24)
3 A Tour of the Standard Library
45(22)
Part I: Basic Facilities 67(154)
4 Types and Declarations
69(18)
5 Pointers, Arrays, and Structures
87(20)
6 Expressions and Statements
107(36)
7 Functions
143(22)
8 Namespaces and Exceptions
165(32)
9 Source Files and Programs
197(24)
Part II: Abstraction Mechanisms 221(206)
10 Classes
223(38)
11 Operator Overloading
261(40)
12 Derived Classes
301(26)
13 Templates
327(28)
14 Exception Handling
355(34)
15 Class Hierarchies
389(38)
Part III: The Standard Library 427(262)
16 Library Organization and Containers
429(32)
17 Standard Containers
461(46)
18 Algorithms and Function Objects
507(42)
19 Iterators and Allocators
549(30)
20 Strings
579(26)
21 Streams
605(52)
22 Numerics
657(32)
Part IV: Design Using C++ 689(102)
23 Development and Design
691(32)
24 Design and Programming
723(42)
25 Roles of Classes
765(26)
Appendices 791(78)
A The C++ Grammar 793(22)
B Compatibility 815(12)
C Technicalities 827(42)
Index 869

Excerpts

The C++ Programming Language, Third Edition Bjarne Stroustrup Preface Programming is understanding. - Kristen NygaardI find using C++ more enjoyable than ever. C++'s support for design and programming has improved dramatically over the years, and lots of new helpful techniques have been developed for its use. However, C++ is notjustfun. Ordinary practical programmers have achieved significant improvements in productivity, maintainability, flexibility, and quality in projects of just about any kind and scale. By now, C++ has fulfilled most of the hopes I originally had for it, and also succeeded at tasks I hadn't even dreamt of.This book introduces standard C++ * and the key programming and design techniques supported by C++. Standard C++ is a far more powerful and polished language than the version of C++ introduced by the first edition of this book. New language features such as name spaces, exceptions, templates, and run-time type identification allow many techniques to be applied more directly than was possible before, and the standard library allows the programmer to start from a much higher level than the bare language.About a third of the information in the second edition of this book came from the first. This third edition is the result of a rewrite of even larger magnitude. It offers something to even the most experienced C++ programmer; at the same time, this book is easier for the novice to approach that its predecessors were. The explosion of C++ use and the massive amount of experience accumulated as a result makes this possible.The definition of an extensive standard library makes a difference to the way C++ concepts can be presented. As before, this book presents C++ independently of any particular implementation, and as before, the tutorial chapters present language constructs and concepts in a "bottom up" order so that a construct is used only after it has been defined. However, it is much easier to use a well-designed library than it is to understand the details of its implementation. Therefore the standard library can be used to provide realistic and interesting examples well before a reader can be assumed to understand its inner workings. the standard library itself is also a fertile source of programming examples and design techniques.This book presents every major C++ language feature and the standard library. It is organized around language and library facilities. However, features are presented in the context of their use. That is, the focus is on the language as the tool for design and programming rather than on the language in itself. This book demonstrates key techniques that make C++ effective and teaches the fundamental concepts necessary for mastery. Except where illustrating technicalities, examples are taken from the domain of systems software. A companion,The Annotated C++ Language Standard, presents the complete language definition together with annotations to make it more comprehensible.The primary aim of this book is to help the reader understand how the facilities offered by C++ support key programming techniques. The aim is to take the reader far beyond the point where he or she gets code running primarily by copying examples and emulation programming styles from other languages. Only a good understanding of the ideas behind the language facilities leads to mastery. Supplemented by implementation documentation, the information provided is sufficient for completing significant real-world projects. The hope is that this book will help the reader gain new insights and become a better programmer and designer.Acknowledgements In addition to the people mentioned in the acknowledgment section of the first and second editions, I would like to thank Matt Austern, Hans Boehm, Don Caldwell, Lawrence Crowl, Alan Feuer, Andrew Forrest, Tim Griffin, Pete

Rewards Program

Reviews for The C++ Programming Language (9780201889543)