Available:*
Library | Item Barcode | Call Number | Material Type | Item Category 1 | Status |
---|---|---|---|---|---|
Searching... | 30000004995050 | QA76.73.C153 D384 2004 | Open Access Book | Book | Searching... |
On Order
Summary
Summary
If you've thought of programmers as elite intelligentsia who possess expertise (and perhaps genes) the rest of us will never have, think again. C++ For Dummies, 5th Edition , debunks the myths, blasts the barriers, shares the secrets, and gets you started. In fact, by the end of Chapter 1, you'll be able to create a C++ program. OK, it won't be newest, flashiest video game, but it might be a practical, customized inventory control or record-keeping program.
Most people catch on faster when they actually DO something, so C++ For Dummies includes a CD-ROM that gives you all you need to start programming (except the guidance in the book, of course), including:
Dev-C, a full-featured, integrated C++ compiler and editor you install to get down to business The source code for the programs in the book, including code for BUDGET, programs that demonstrate principles in the book Documentation for the Standard Template Library Online C++ help filesWritten by Stephen Randy Davis, author of C++ Weekend Crash Course, C++ for Dummies, takes you through the programming process step-by-step. You'll discover how to:
Generate an executable Create source code, commenting it as you go and using consistent code indentation and naming conventions Write declarations and name variables, and calculate expressions Write and use a function, store sequences in arrays, and declare and use pointer variables Understand classes and object-oriented programming Work with constructors and destructors Use inheritance to extend classes Use stream I/O Comment your code as you go, and use consistent code indentation and naming conventions Automate programming with the Standard Template Library (STL)C++ for Dummies 5th Edition is updated for the newest ANSI standard to make sure you're up to code.
Note: CD-ROM/DVD and other supplementary materials are not included as part of eBook file.
Author Notes
Stephen Randy Davis is a bestselling author with thirty years of programming experience
Reviews 1
Library Journal Review
C++ remains a strong contender among object-oriented programming languages (see Computer Media, LJ 6/1/03), and updated guides are always useful. C++ for Dummies assumes no previous programming experience, befitting the view of C++ as a foundational language. It includes source code, sample program, online help files, and the Dev-C++ compiler/editor on CD-ROM. Coverage ranges from how to enter, compile, and execute a program to using templates, while the "Part of Tens" sections at the end cover the most important optional features of Dev-C++ and ways to avoid adding bugs. A supplemental purchase to more thorough guides; for medium and larger libraries. Eschewing the basics, Art shows intermediate programmers the power of the language and how it applies to a range of programming tasks. Source code for sometimes extensive examples is available online. Extensive background and explanations-as well as an obvious enthusiasm for the language-make this a useful guide for those wanting to delve further. Recommended for larger libraries. (c) Copyright 2010. Library Journals LLC, a wholly owned subsidiary of Media Source, Inc. No redistribution permitted.
Table of Contents
Introduction | p. 1 |
What's in This Book | p. 1 |
What's on the CD | p. 2 |
What Is C++? | p. 2 |
Conventions Used in This Book | p. 2 |
How This Book Is Organized | p. 3 |
And There's More | p. 4 |
Part 1 Introduction to C++ Programming | p. 7 |
Chapter 1 Writing Your First C++ Program | p. 9 |
Grasping C++ Concepts | p. 10 |
Installing Dev-C++ | p. 12 |
Creating Your First C++ Program | p. 16 |
Executing Your Program | p. 20 |
Reviewing the Annotated Program | p. 21 |
Calculating Expressions | p. 25 |
Chapter 2 Declaring Variables Constantly | p. 27 |
Declaring Variables | p. 27 |
Declaring Different Types of Variables | p. 28 |
Declaring Variable Types | p. 33 |
Are These Calculations Really Logical? | p. 36 |
Mixed Mode Expressions | p. 36 |
Chapter 3 Performing Mathematical Operations | p. 39 |
Performing Simple Binary Arithmetic | p. 40 |
Decomposing Expressions | p. 41 |
Determining the Order of Operations | p. 42 |
Performing Unary Operations | p. 43 |
Using Assignment Operators | p. 45 |
Chapter 4 Performing Logical Operations | p. 47 |
Why Mess with Logical Operations? | p. 47 |
Using the Simple Logical Operators | p. 48 |
Expressing Binary Numbers | p. 53 |
Performing Bitwise Logical Operations | p. 56 |
Chapter 5 Controlling Program Flow | p. 61 |
Controlling Program Flow with the Branch Commands | p. 61 |
Executing Loops in a Program | p. 63 |
Nesting Control Commands | p. 73 |
Switching to a Different Subject? | p. 74 |
Part II Becoming a Functional C++ Programmer | p. 77 |
Chapter 6 Creating Functions | p. 79 |
Writing and Using a Function | p. 79 |
Understanding the Details of Functions | p. 83 |
Overloading Function Names | p. 87 |
Defining Function Prototypes | p. 89 |
Variable Storage Types | p. 91 |
Including Include Files | p. 91 |
Chapter 7 Storing Sequences in Arrays | p. 93 |
Considering the Need for Arrays | p. 93 |
Using Arrays of Characters | p. 100 |
Manipulating Strings with Character | p. 103 |
String-ing Along Variables | p. 106 |
Chapter 8 Taking a First Look at C++ Pointers | p. 109 |
Variable Size | p. 109 |
What's in an Address? | p. 110 |
Address Operators | p. 111 |
Using Pointer Variables | p. 112 |
Passing Pointers to Functions | p. 117 |
Making Use of a Block of Memory Called the Heap | p. 119 |
Chapter 9 Taking a Second Look at C++ Pointers | p. 125 |
Defining Operations on Pointer Variables | p. 125 |
Declaring and Using Arrays of Pointers | p. 133 |
Chapter 10 Debugging C++ | p. 139 |
Identifying Types of Errors | p. 139 |
Choosing the WRITE Technique for the Problem | p. 140 |
Calling for the Debugger | p. 146 |
Part III Introduction to Classes | p. 155 |
Chapter 11 Examining Object-Oriented Programming | p. 157 |
Abstracting Microwave Ovens | p. 157 |
Classifying Microwave Ovens | p. 159 |
Why Classify? | p. 160 |
Chapter 12 Adding Class to C++ | p. 161 |
Introducing the Class | p. 161 |
The Format of a Class | p. 162 |
Accessing the Members of a Class | p. 163 |
Chapter 13 Making Classes Work | p. 167 |
Activating Our Objects | p. 168 |
Adding a Member Function | p. 169 |
Calling a Member Function | p. 171 |
Scope Resolution (And I Don't Mean How Well Your Microscope Works) | p. 175 |
Defining a Member Function in the Class | p. 177 |
Keeping a Member Function After Class | p. 179 |
Overloading Member Functions | p. 181 |
Chapter 14 Point and Stare at Objects | p. 183 |
Defining Arrays of and Pointers to Simple Things | p. 183 |
Declaring Arrays of Objects | p. 184 |
Declaring Pointers to Objects | p. 185 |
Passing Objects to Functions | p. 187 |
Why Bother with Either Pointers or References? | p. 192 |
Returning to the Heap | p. 192 |
Comparing Pointers to References | p. 193 |
Why Not Use References Rather Than Pointers? | p. 193 |
Linking Up with Linked Lists | p. 195 |
A Ray of Hope: A List of Containers Linked to the C++ Library | p. 200 |
Chapter 15 Protecting Members: Do Not Disturb | p. 201 |
Protecting Members | p. 201 |
Making an Argument for Using Protected Members | p. 204 |
Giving Non-Member Functions Access to Protected Members | p. 205 |
Chapter 16 "Why Do You Build Me Up, Just to Tear Me Down, Baby?" | p. 209 |
Creating Objects | p. 209 |
Using Constructors | p. 210 |
Dissecting a Destructor | p. 217 |
Chapter 17 Making Constructive Arguments | p. 221 |
Outfitting Constructors with Arguments | p. 221 |
Placing Too Many Demands on the Carpenter: Overloading the Constructor | p. 223 |
Defaulting Default Constructors | p. 227 |
Constructing Class Members | p. 228 |
Constructing the Order of Construction | p. 233 |
Chapter 18 Copying the Copy Copy Copy Constructor | p. 239 |
Copying an Object | p. 239 |
The Automatic Copy Constructor | p. 242 |
Creating Shallow Copies versus Deep Copies | p. 244 |
It's a Long Way to Temporaries | p. 248 |
Chapter 19 Static Members: Can Fabric Softener Help? | p. 251 |
Defining a Static Member | p. 251 |
Declaring Static Member Functions | p. 255 |
What Is This About, Anyway? | p. 258 |
Part IV Inheritance | p. 259 |
Chapter 20 Inheriting a Class | p. 261 |
Do I Need My Inheritance? | p. 262 |
How Does a Class Inherit? | p. 263 |
Having a HAS_A Relationship | p. 267 |
Chapter 21 Examining Virtual Member Functions: Are They for Real? | p. 269 |
Why You Need Polymorphism | p. 272 |
How Polymorphism Works | p. 274 |
When Is a Virtual Function Not? | p. 276 |
Considering Virtual Considerations | p. 277 |
Chapter 22 Factoring Classes | p. 279 |
Factoring | p. 279 |
Implementing Abstract Classes | p. 284 |
Factoring C++ Source Code | p. 291 |
Part V Optional Features | p. 303 |
Chapter 23 A New Assignment Operator, Should You Decide to Accept It | p. 305 |
Comparing Operators with Functions | p. 305 |
Inserting a New Operator | p. 306 |
Creating Shallow Copies Is a Deep Problem | p. 307 |
Overloading the Assignment Operator | p. 308 |
Protecting the Escape Hatch | p. 311 |
Chapter 24 Using Stream I/O | p. 313 |
How Stream I/O Works | p. 313 |
The fstream Subclasses | p. 315 |
Reading Directly from a Stream | p. 320 |
What's Up with endl? | p. 322 |
Using the strstream Subclasses | p. 322 |
Manipulating Manipulators | p. 325 |
Chapter 25 Handling Errors--Exceptions | p. 329 |
Justifying a New Error Mechanism? | p. 331 |
Examining the Exception Mechanism | p. 332 |
What Kinds of Things Can I Throw? | p. 335 |
Chapter 26 Inheriting Multiple Inheritance | p. 339 |
Describing the Multiple Inheritance Mechanism | p. 339 |
Straightening Out Inheritance Ambiguities | p. 341 |
Adding Virtual Inheritance | p. 342 |
Constructing the Objects of Multiple Inheritance | p. 349 |
Voicing a Contrary Opinion | p. 349 |
Chapter 27 Tempting C++ Templates | p. 351 |
Generalizing a Function into a Template | p. 353 |
Template Classes | p. 355 |
Do I Really Need Template Classes? | p. 358 |
Tips for Using Templates | p. 361 |
Chapter 28 Standardizing on the Standard Template Library | p. 363 |
The string Container | p. 364 |
The list Containers | p. 366 |
Iterators | p. 368 |
Using Maps | p. 371 |
Part VI The Part of Tens | p. 375 |
Chapter 29 Ten Ways to Avoid Adding Bugs to Your Program | p. 377 |
Enabling All Warnings and Error Messages | p. 377 |
Insisting on Clean Compiles | p. 378 |
Adopting a Clear and Consistent Coding Style | p. 379 |
Limiting the Visibility | p. 379 |
Commenting Your Code While You Write It | p. 381 |
Single-Stepping Every Path at Least Once | p. 381 |
Avoid Overloading Operators | p. 382 |
Heap Handling | p. 382 |
Using Exceptions to Handle Errors | p. 382 |
Avoiding Multiple Inheritance | p. 383 |
Chapter 30 The Ten Most Important Optional Features of Dev-C++ | p. 385 |
Customize Editor Settings to Your Taste | p. 385 |
Highlight Matching Braces/Parentheses | p. 386 |
Enable Exception Handling | p. 387 |
Include Debugging Information (Sometimes) | p. 387 |
Create a Project File | p. 388 |
Customize the Help Menu | p. 388 |
Reset Breakpoints after Editing the File | p. 388 |
Avoid Illegal Filenames | p. 389 |
Include #include Files in Your Project | p. 389 |
Executing the Profiler | p. 389 |
Appendix About the CD | p. 393 |
System Requirements | p. 393 |
Using the CD with Microsoft Windows | p. 394 |
Using the CD with Linux | p. 395 |
What You'll Find | p. 396 |
Development tools | p. 396 |
Program source code | p. 397 |
If You've Got Problems (Of the CD Kind) | p. 397 |
Bonus Chapters on the CD-ROM! | p. CD |
Bonus Chapter 1 A Functional Budget Program | p. BC1 |
Budget1 | p. BC1 |
Budget2 | p. BC7 |
Budget3 | p. BC16 |
Budget4 | p. BC28 |
Budget5 | p. BC37 |
Bonus Chapter 2 Using Visual C++.NET | p. BC45 |
Building a Project | p. BC45 |
Adding an Existing Program to an Existing Project | p. BC47 |
Creating a New Program Project | p. BC49 |
Index | p. 407 |