Sams Teach Yourself C++ in One Hour a Day 7th Edition
| Siddhartha Rao (Author) Find all the books, read about the author, and more. See search results for this author |
Use the Amazon App to scan ISBNs and compare prices.
Completely updated for the C++11 standard, Sams Teach Yourself C++ in One Hour a Day presents the language from a practical point of view, helping you learn how to use C++11 to create faster, simpler, and more efficient C++ applications.
- Master the fundamentals of C++ and object-oriented programming
- Understand how C++11 features help you write compact and efficient code using concepts such as lambda expressions, move constructors, and assignment operators
- Learn the Standard Template Library, including containers and algorithms used in most real-world C++ applications
- Test your knowledge and expertise using exercises at the end of every lesson
Learn on your own time, at your own pace:
- No previous programming experience required
- Learn C++11, object-oriented programming, and analysis
- Write fast and powerful C++ programs, compile the source code with a gcc compiler, and create executable files
- Use the Standard Template Library’s (STL) algorithms and containers to write feature-rich yet stable C++ applications
- Develop sophisticated programming techniques using lambda expressions, smart pointers, and move constructors
- Learn to expand your program’s power with inheritance and polymorphism
- Master the features of C++ by learning from programming experts
- Learn C++11 features that allow you to program compact and high-performance C++ applications
PART I: THE BASICS
LESSON 1: Getting Started with C++11
LESSON 2: The Anatomy of a C++ Program
LESSON 3: Using Variables, Declaring Constants
LESSON 4: Managing Arrays and Strings
LESSON 5: Working with Expressions, Statements, and Operators
LESSON 6: Controlling Program Flow
LESSON 7: Organizing Code with Functions
LESSON 8: Pointers and References Explained
PART II: FUNDAMENTALS OF OBJECT-ORIENTED C++ PROGRAMMING
LESSON 9: Classes and Objects
LESSON 10: Implementing Inheritance
LESSON 11: Polymorphism
LESSON 12: Operator Types and Operator Overloading
LESSON 13: Casting Operators
LESSON 14: An Introduction to Macros and Templates
PART III: LEARNING THE STANDARD TEMPLATE LIBRARY (STL)
LESSON 15: An Introduction to the Standard Template Library
LESSON 16: The STL String ClassLESSON 17: STL Dynamic Array Classes
LESSON 18: STL list and forward_list
LESSON 19: STL Set Classes
LESSON 20: STL Map Classes
PART IV: MORE STL
LESSON 21: Understanding Function Objects
LESSON 22: C++11 Lambda ExpressionsLESSON 23: STL Algorithms
LESSON 24: Adaptive Containers: Stack and Queue
LESSON 25: Working with Bit Flags Using STL
PART V: ADVANCED C++ CONCEPTS
LESSON 26: Understanding Smart Pointers
LESSON 27: Using Streams for Input and OutputLESSON 28: Exception Handling
LESSON 29: Going Forward
APPENDIXES
A: Working with Numbers: Binary and Hexadecimal
B: C++ Keywords
C: Operator Precedence
D: Answers
E: ASCII Codes
Customers who viewed this item also viewed
Customers who bought this item also bought
Editorial Reviews
From the Back Cover
Learn C++ in Just One Hour a Day!
In just one hour a day, you’ll have all the skills you need to begin programming in C++. With this complete tutorial, you’ll quickly master the basics, and then move on to more advanced features and concepts.
Completely updated for the C++11 standard, Sams Teach Yourself C++ in One Hour a Day — the seventh edition of Sams Teach Yourself C++ in 21 Days — presents the language from a practical point of view, helping you learn how to use C++11 to create faster, simpler, and more efficient C++ applications.
- Master the fundamentals of C++ and object-oriented programming
- Understand how C++11 features help you write compact and efficient code using concepts such as lambda expressions, move constructors, and assignment operators
- Learn best practices and avoid pitfalls via useful Do’s and Don’ts
- Learn the Standard Template Library, including containers and algorithms used in most real-world C++ applications
- Test your knowledge and expertise using exercises at the end of every lesson
Learn on your own time, at your own pace:
- No previous programming experience required
- Learn C++11, object-oriented programming, and analysis
- Write fast and powerful C++ programs, compile the source code, and create executable files
- Use the Standard Template Library’s algorithms and containers to write feature-rich yet stable C++ applications
- Develop sophisticated programming techniques using lambda expressions, smart pointers, and move constructors
- Learn to expand your program’s power with inheritance and polymorphism
- Master the features of C++ by learning from programming experts
- Learn C++11 features that allow you to program compact and high-performance C++ applications
About the Author
Siddhartha Rao is a technologist at SAP AG, the world’s leading supplier of enterprise software. As the head of SAP Product Security India, his primary responsibilities include hiring expert talent in the area of product security as well as defining development best practices that keeps SAP software globally competitive. Awarded Most Valuable Professional by Microsoft for Visual Studio–Visual C++, he is convinced that C++11 will help you program faster, simpler, and more efficient C++ applications.
Siddhartha also loves traveling and discovering new cultures given an opportunity to. For instance, parts of this book have been composed facing the Atlantic Ocean at a quaint village called Plogoff in Brittany, France—one of the four countries this book was authored in. He looks forward to your feedback on this global effort!
I'd like to read this book on Kindle
Don't have a Kindle? Get your Kindle here, or download a FREE Kindle Reading App.
Product details
- Publisher : Sams Publishing; 7th edition (May 10, 2012)
- Language : English
- Paperback : 766 pages
- ISBN-10 : 0672335670
- ISBN-13 : 978-0672335679
- Item Weight : 2.61 pounds
- Dimensions : 7 x 1.73 x 9.13 inches
- Best Sellers Rank: #1,402,961 in Books (See Top 100 in Books)
- #562 in C++ Programming Language
- #1,025 in Object-Oriented Design
- #3,807 in Computer Programming Languages
- Customer Reviews:
About the author

Born in Mumbai to parents from different cultures, Siddhartha grew up speaking four languages and learning many more. Awarded Most Valuable Professional for Visual C++ by Microsoft, he has two decades of experience in software development and is recognized for his contribution to the software community at CodeGuru.com. As the Vice President in charge of Security Response at SAP SE, his responsibilities include helping SAP develop secure and trustworthy products.
Customer reviews
Top reviews from the United States
There was a problem filtering reviews right now. Please try again later.
Using the Third Printing April 2013, I find very few typos or grammar troubles like another reviewer complains. In fact, very much the opposite - this writer conveys every nuance of the language with clear and direct language. It is the easy style, the directness, and most of all - the motivated introduction to concepts that sets this book far above many of the other programming language introductory books I've read (specific to C++: 'C++ Primer' and 'A Tour of C++').
The book covers the language itself in about 300 pages. The remainder of the book covers the STL with another 300 pages.
Every concept is given a complete and to-the-point working example program so you can get used to reading complete programs, not just snippets of right and wrong lines like C++ Primer does.
You're given a set of guidelines to follow at the end of important concepts (DOs & DON'Ts), and at the end of each chapter is an informative Q&A where you can almost listen in to real world 'classroom' type questions and their answers.
The back of the book contains all answers to review/exercise questions. Also of interest are the BUG BUSTER questions which show you small (yet complete) programs for you to debug.
In short, this is THE book to get started with C++11. I tried others, but this one is finally teaching me without frustration in a motivated way - explaining not only the how but the WHY and doing so in plain language that is consistently easy to understand.
By the way, ... just noting a few other reviews directing to the 5th edition by Jesse Liberty.. I've had the displeasure of reading a few other books he has authored and was very disappointed by the writing style. Just my opinion.
But as someone who is fluent in Java and C (and a little C++), the naming convention for variables really throws me off! I know I might be a little picky here, but the author uses pascal case for variables... but every team I have ever been involved in has used camel case for variables (or standard c / gnu notation with underscores) and pascal case only for things like class names or types. He uses Pascal case for methods too.. I'm only about halfway through though, so I'm not sure if this persists throughout the entire book. I guess I'll just have to get used to it.
This makes it really hard for me to read for some reason because the class types and variable names have the same naming convention.
Due to the two major cons below, I will not recommend this book, but instead recommend two others:
1) SAMS Teach Yourself C++ in 21 Days (5th Edition). If you want to learn C++ from scratch and have any trouble at all following other books, that book will be a godsend for you.
2) Once you finish that book, pick up The C++ Standard Library to learn about the STL and newer C++11 features in greater depth.
/********** PROS **********/
1) The same wonderful layout that SAMS books are known for. It makes quick referencing and look-up of key points easy.
2) Covers more of the STL than older editions.
/********** CONS **********/
1). The author in this book is not nearly as user-friendly in their explanations as authors of the 5th edition. While writing a tutorial on functions for my students, I looked to this book as a reference. The very first sentence on functions in this book is the following:
"Functions in C++ are the same as functions in C. Functions are artifacts that enable you to divide the content of your application into functional units that can be invoked in a sequence of your choosing."
The first problem with this introduction line is that this book is for beginners who probably don't know C, so that's a dumb assumption to make. The second problem with it is that telling a beginner that functions are artifacts does nothing to enhance their understanding of them - it is a waste of text that bogs down the reader's brain with unnecessary blather. Both of these points are part of the main problem which is that this is an absolutely HORRIBLE explanation in general for the novice this book is targeted at. No student of mine will learn from language like this.
By contrast, the 5th edition introduces functions like this:
"A function is, in effect, a subprogram that can act on data and return a value. Every C++ program has at least one function, main(). When your program starts, the main() function is called automatically...
... Each function has its own name, and when that name is encountered, the execution of the program branches to the body of that function."
This is clearly a much better way to convey this information to a learning student. Telling them that writing the function name causes the code inside the function to happen is a lot easier to grasp than saying that functions are artifacts and are just like C ones.
It's not just the section on functions that is written this way either. The whole book goes on like this, which may account for why this newer edition has about half the page count of the older one. I always recommended the 5th edition as the one book nobody could possibly get lost in while learning, but the 7th edition is a real disappointment in continuing that trend.
2) The book advertises C++11 on the cover. While it does cover some C++11 features, it leaves out many that really belong in this book (e.g. default and delete keywords for constructors). This may be due in part to writing code that will compile on the edition of Visual Studio the author is using, whose compiler is not fully standards-compliant with C++11 yet (at the time of this writing). However, these features ARE supported on other compilers. Even if you don't want to confuse the reader with code that won't work on the suggested IDE/compiler, it at least deserves a passing mention since it's supposed to be STANDARD C++, not Microsoft's C++. Older editions of this book were sure mention things like this.
My suggestion to the publisher:
Dump Siddhartha Rao and bring back Jesse Liberty and the other guy.
UPDATE: Wow, I hadn't anticipated so much attention on this review, but I'm glad to see so many have found it helpful. A few notes to add since the original writing of this review:
* The latest Visual Studio compilers are compliant with most if not all C++11 (and 14/17) features that any C++ beginner should be introduced to.
* My recommendation still stands! I still have yet to find a better introductory C++ book than that SAMS 5th edition, and I still strongly recommend starting there and continuing with a secondary book that includes the newer C++ language additions after you've got a decent grasp on the basics. I believe the C++ Standard Library 2nd edition is still a good resource, but many other new ones have since sprung up as well, so go ahead and look around.
* The most common question I've been asked since making this recommendation here and in other locations is for a book recommendation to advance from beginner to intermediate level, so my updated (as of late 2016) answer to that is: Effective Modern C++.
Top reviews from other countries
WARNING: Although C++11 compliant, many of the books examples will NOT compile when using the latest on-line version of VC++ (2017 as of now) because Microsoft deprecated some basic functions (strcpy() for example) as "unsafe" and will fail any "run" or "build attempt. I had to go back to VC++ 2008 to run these examples. No update expected since this book is no longer in print and supported by Sam's Publishing, now Parson InformIT. I removed a star for this reason.








