Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

off on a tangent: does anyone know a good resource/book for learning C++ from a C background? I've loathed C++ every time I've gone to use it, I'm sure there's something good in there....

i.e. is there a good book "C++ for C programmers who hate the thought of it"



Accelerated C++ (http://www.amazon.com/dp/020170353X) is perfect. I learned C++ from a C background and this book is written exactly for people like us.


I'd recommend "C++ Primer". It's been updated for C++11, and is written in precise and clear language. As a C programmer, I find understanding details are important; Accelerated C++ was just too chatty, casual, and vague for my tastes.


thanks. added to amazon wishlist


There is nothing good in there! Run away! :P There are reasons companies like Google et al. strictly enforce their developers to use only a subset of C++, or to use it as an "augmented C". There's also this fun problem as you learn and use it: http://lbrandy.com/blog/wp-content/uploads/2010/03/c++.png

http://yosefk.com/c++fqa/index.html isn't a book, but the author shares your disgust for C++ and it's fairly detailed. As he says somewhere, he knows C++ better than it deserves to be known. I also don't like C++ as much as C (and I'd like to replace ever having to use either of them with Rust, hence Rust is my language-of-the-year to learn for 2013), and I found the FQA immensely useful for understanding the craziness and defectiveness of C++.

I'd also recommend http://www.amazon.com/The-Standard-Library-Tutorial-Referenc... I own the first edition and found it useful.


There is a thread on Stack Overflow that has a pretty good list http://stackoverflow.com/questions/388242/the-definitive-c-b... I'm currently working my way through Accelerated C++ and I'm finding it to be an excellent resource


I found the scott meyers books to be good (effective C++ and effective STL)


I particularly like the -Weffc++ ;)


These require some background in C++ before you pick them up, however.


That is true. Those books take "C programmers with a very basic understanding of some C++ fundamentals" to "C++ programmers"


They are very good, particularly for the intermediate C++ programmer.


I'd suggest the course reader from Stanford's CS 106L, authored by Keith Schwarz. It brought me upto speed on major parts of STL, the C++ object model, operator overloading, functors, etc. within a week. (Of course that's assuming you have a prior programming background).




Consider applying for YC's Fall 2026 batch! Applications are open till July 27.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: