[Home]  [Edit this page]  [Recent Changes]  [Special Pages]  [Help
CppBooks

(C++ FAQ) Which books should I read when I learn C++?

There are many C++ books for starters. I would recommend to start with a book you just like the writing style of. However, there are many programming books out there that get you into bad habits. When selecting for a book, pay attention to the following:

  • It should use 'int main' instead of 'void main' [1-5]
  • It should use string, instead of char*[6-10]
  • It should use vector, instead of arrays[6-10]
  • It should use cout, instead of printf (which is an unsafe C function)
  • It should not encourage the use of macro's [11,12]
  • It should encourage the use of const[13-17]
A book that does all of the above is 'Thinking C++' by Bruce Eckel, can be downloaded for free. Try Google!

When getting the hang of programming and wondering about 'good practices', 'good naming conventions' and so on, I stronly recommend 'C++ coding standards: 101 rules, guidelines, and best practices'[6]. Put it under your pillow, read some pages once in a while and gain huge benfits.

To deepen your knowledge about C++, I'd recommend 'The C++ Programming Language' [10] from Bjarne Stroustrup.

To improve you class design using design patterns, I'd recommend the book 'Design Patterns' [18].

To deepen your insight about the philosphy behind C++, read 'The design and evolution of C++'[19], also from Bjarne Stroustrup.

Other suggestions

The most important C++ books ...ever

The most important C++ books are (according to [20]):

'Books' links

References

  • 1) C++. International Standard. ISO/IEC 14882. Second edition. Paragraph 3.6.1.2
  • 2) From http://www.parashift.com/c++-faq-lite/newbie.html#faq-29.3 : main() must return int. Not void, not bool, not float. int. Just int, nothing but int, only int. Some compilers accept void main(), but that is non-standard and shouldn't be used. Instead use int main().
  • 3) Herb Sutter. Exceptional C++. ISBN: 0-201-61562-2. Item 21: void main() is nonstandard and nonportable.
  • 4) From Bjarne Stroustrup's homepage (http://www.research.att.com/~bs/bs_faq2.html#void-main) :
The definition
void main() { /* ... */ }
is not and never has been C++, nor has it even been C.


last edited (January 2, 2007) by bilderbikkel, Number of views: 3819, Current Rev: 9 (Diff)

[Edit this page]  [Page history]  [What links here]  [Discuss this topic]  [Printer Friendly]  

Members

Username:

Password:


Register
Forgot Password?




Programmers Heaven - for .NET, Java, C/C++ and WEB Developers!
© 1996-2008 Community Networks Ltd. All rights reserved. Reproduction in whole or in part, in any form or medium without express written permission is prohibited. Violators of this policy may be subject to legal action. Please read Terms Of Use and Privacy Statement for more information. Development by Tore Nestenius at .NET Consultant - Synchron Data.