Apress.Exploring.C.Plus.Plus.The.Programmers.Introduction.To.C.Plus.Plus.Dec.2008.eBook-ELOHiM.pdf
(
2355 KB
)
Pobierz
Exploring C++
The Programmer’s Introduction
to C++
Ray Lischner
Exploring C++: The Programmer’s Introduction to C++
Copyright © 2009 by Ray Lischner
All rights reserved. No part of this work may be reproduced or transmitted in any form or by any means,
electronic or mechanical, including photocopying, recording, or by any information storage or retrieval
system, without the prior written permission of the copyright owner and the publisher.
ISBN-13 (pbk): 978-1-59059-749-1
ISBN-10 (pbk): 1-59059-749-4
ISBN-13 (electronic): 978-1-4302-1895-1
Printed and bound in the United States of America 9 8 7 6 5 4 3 2 1
Trademarked names may appear in this book. Rather than use a trademark symbol with every occurrence
of a trademarked name, we use the names only in an editorial fashion and to the benefit of the trademark
owner, with no intention of infringement of the trademark.
Lead Editor: Matthew Moodie
Technical Reviewer: Francis Glassborow
Editorial Board: Clay Andres, Steve Anglin, Mark Beckner, Ewan Buckingham, Tony Campbell,
Gary Cornell, Jonathan Gennick, Michelle Lowman, Matthew Moodie, Jeffrey Pepper,
Frank Pohlmann, Ben Renow-Clarke, Dominic Shakeshaft, Matt Wade, Tom Welsh
Project Manager: Richard Dal Porto
Copy Editor: Octal Publishing, Inc.
Associate Production Director: Kari Brooks-Copony
Production Editor: Ellie Fountain
Compositor: Dina Quan
Proofreaders: Lisa Hamilton and Linda Seifert
Indexer: John Collin
Cover Designer: Kurt Krames
Manufacturing Director: Tom Debolski
Distributed to the book trade worldwide by Springer-Verlag New York, Inc., 233 Spring Street, 6th Floor,
New York, NY 10013. Phone 1-800-SPRINGER, fax 201-348-4505, e-mail
kn`ano)ju<olnejcan)o^i*_ki
, or
visit
dppl6++sss*olnejcankjheja*_ki
.
For information on translations, please contact Apress directly at 2855 Telegraph Avenue, Suite 600,
Berkeley, CA 94705. Phone 510-549-5930, fax 510-549-5939, e-mail
ejbk<]lnaoo*_ki
, or visit
dppl6++sss*]lnaoo*_ki
.
Apress and friends of ED books may be purchased in bulk for academic, corporate, or promotional use.
eBook versions and licenses are also available for most titles. For more information, reference our Special
Bulk Sales–eBook Licensing web page at
dppl6++sss*]lnaoo*_ki+ejbk+^qhgo]hao
.
The information in this book is distributed on an “as is” basis, without warranty. Although every precau-
tion has been taken in the preparation of this work, neither the author nor Apress shall have any liability
to any person or entity with respect to any loss or damage caused or alleged to be caused directly or indi-
rectly by the information contained in this work.
The source code for this book is available to readers at
dppl6++sss*]lnaoo*_ki
. You may need to answer
questions pertaining to this book in order to successfully download the code.
Contents at a Glance
About the Author
..................................................................xxi
About the Technical Reviewer
.....................................................xxiii
Acknowledgments
............................................................... xxv
Introduction
.....................................................................xxvii
PART 1
NNN
The Basics
EXPLORATION 1
Honing Your Tools
............................................3
EXPLORATION 2
Reading C++ Code
..........................................13
EXPLORATION 3
Integer Expressions
..........................................21
EXPLORATION 4
Strings
......................................................27
EXPLORATION 5
Simple Input
................................................33
EXPLORATION 6
Error Messages
.............................................39
EXPLORATION 7
For Loops
...................................................45
EXPLORATION 8
Formatted Output
............................................49
EXPLORATION 9
Arrays and Vectors
..........................................59
EXPLORATION 10
Increment and Decrement
...................................71
EXPLORATION 11
Conditions and Logic
........................................77
EXPLORATION 12
Compound Statements
.......................................85
EXPLORATION 13
Introduction to File I/O
.......................................95
EXPLORATION 14
The Map Data Structure
......................................99
EXPLORATION 15
Type Synonyms
............................................105
EXPLORATION 16
Characters
.................................................109
EXPLORATION 17
Character Categories
.......................................115
EXPLORATION 18
Case-Folding
...............................................123
EXPLORATION 19
Writing Functions
...........................................127
EXPLORATION 20
Function Arguments
........................................137
iii
iv
N
CONTENTS AT A GLANCE
EXPLORATION 21
Using Algorithms
...........................................145
EXPLORATION 22
Overloading Function Names
................................157
EXPLORATION 23
Big and Little Numbers
.....................................163
EXPLORATION 24
Very Big and Very Little Numbers
............................173
EXPLORATION 25
Documentation
.............................................181
EXPLORATION 26
Project 1: Body-Mass Index
.................................189
PART 2
NNN
Custom Types
EXPLORATION 27
Custom Types
..............................................195
EXPLORATION 28
Overloading Operators
......................................203
EXPLORATION 29
Custom I/O Operators
.......................................213
EXPLORATION 30
Assignment and Initialization
................................219
EXPLORATION 31
Writing Classes
.............................................227
EXPLORATION 32
More About Member Functions
..............................235
EXPLORATION 33
Access Levels
..............................................247
EXPLORATION 34
Introduction to Object-Oriented Programming
................257
EXPLORATION 35
Inheritance
.................................................265
EXPLORATION 36
Virtual Functions
...........................................275
EXPLORATION 37
Classes and Types
..........................................283
EXPLORATION 38
Declarations and Definitions
................................293
EXPLORATION 39
Using Multiple Source Files
.................................305
EXPLORATION 40
Function Objects
...........................................321
EXPLORATION 41
Useful Algorithms
..........................................331
EXPLORATION 42
Iterators
...................................................345
EXPLORATION 43
Exceptions
.................................................357
EXPLORATION 44
More Operators
.............................................373
EXPLORATION 45
Project 2: Fixed-Point Numbers
.............................385
PART 3
NNN
Generic Programming
EXPLORATION 46
Function Templates
.........................................393
EXPLORATION 47
Class Templates
............................................405
EXPLORATION 48
Template Specialization
....................................415
Plik z chomika:
ms500
Inne pliki z tego folderu:
Professional_Cpp_3rd_edition.pdf
(12683 KB)
Advanced.C.and.C++.Compiling.pdf
(29765 KB)
Addison.Wesley.C.Plus.Plus.Primer.Plus.6th.Edition.2012.pdf
(7886 KB)
Addison.Wesley.Problem.Solving.with.C++.7th.Edition.pdf
(246895 KB)
Addison.Wesley.The.Cpp.Programming.Language-Bjarne.Stroustrup-1997.pdf
(5964 KB)
Inne foldery tego chomika:
APACHE_TOMCAT_JBOSS
ASSEMBLY.LANGUAGE
BSD
C
C.Sharp
Zgłoś jeśli
naruszono regulamin