6 ms·
I have some C programming experience and I wanted to learn C++ so I bought and started reading Stoustrop's book, thinking it's the K&R of C++. It's the worst p
by saurabhjha 10y ago
I have some C programming experience and I wanted to learn C++ so I bought and started reading Stoustrop's book, thinking it's the K&R of C++.
It's the worst programming book I have ever read! It's introduction made me hate C++ and if I didn't had to work with other C++ libraries, I would have avoided C++. The text is full of bloat, for the lack of better word. It's the opposite of crisp writing.
I read some good language books like K&R's C, Joe Armstrong's Erlang book. I loved them and I thought this would be in same league. It's not.
I would like to learn C++ systematically, like not cut-and-paste stuff. "How to think like a computer scientist: C++" seems like a good book. I read the book "How to think like a computer scientist", which is an introduction to programming in Python. I think that would be a good start. Is it a good book for experienced programmers wanting to learn C++?
To people wanting to learn C++, please avoid Stoustrop's book like Plague.
EDIT: I read "The C++ programming language 4th edition" which explains C++11 https://en.wikipedia.org/wiki/The_C%2B%2B_Programming_Language https://en.wikipedia.org/wiki/The_C%2B%2B_Programming_Langua...
- ylk 10y agoWould you please define which of his books you read? Just saying "Stoustrop's book" doesn't really help anybody. He wrote a few books, as you can see here: http://www.stroustrup.com/books.html http://www.stroustrup.com/books.html
- saurabhjha 10y agoEdited original comment. Sorry for the confusion.
- flatline 10y agoAs someone who knows a number of programming languages more or less fluently, I found that book to be invaluable when I started working in C++ professionally. It's not a book to teach you programming or any of the General concepts of OOP, FP, or the like. It is, however, a great resource for learning C++ assuming you know the high level concepts already.
- muyuu 10y ago>thinking it's the K&R of C++. You nailed it with that analogy though. K&R is a "first book" and important historically, but right now it's an atrocious book if you want to learn current C and this has been the case for a long, long time. Sometimes these first books don't withstand the test of time.
- jdhopeunique 10y agoWhat's a good book for learning current C?
- curiousgal 10y agoBen Klemens' 21st Century C is good.
- AsyncAwait 10y agoI can recommend "C Programming: A Modern Approach 2nd Ed."[1]. 1 - http://knking.com/books/c2/index.html http://knking.com/books/c2/index.html
- ChristianGeek 10y agoEven though it was published in 2008?
- AsyncAwait 10y agoAbsolutely! There's not a whole lot that's changed in C11, (C is kind of "done" at this point) and there's not been a newer book that teaches the language so well.
- ska 10y agoThat's not entirely fair - it's not just about being first. K&R may be archaic now, even obsolete. However, for decades it has was held up as a an example of what a good technical/language book could be. You don't have to agree with the assessment to agree with the fact - that this was touted as a very good technical book for various reasons. There never was a "K&R" of C++. That's not unusual, many languages are in the same boat. If you want to go back to the "firsts" it would be a combination of The C++ Primer and Strousoup, putting them together gave you something that was both more and less that K&R was for C.
- deleted 10y ago[deleted]
- strmpnk 10y agoWhile it's rather introductory, "A Tour of C++" is a much more concise book. Read that and then maybe look at some Scott Meyers books (I haven't read "Effective Modern C++" but the other entries in the series are good and I'd expect this to be a good place to start after the tour book).
- manaskarekar 10y agoThat book works well as a reference, as a supplement to the C++ Primer, 5th Edition. Not to be confused with C++ Primer Plus.
- _cx2w 10y ago> The text is full of bloat, for the lack of better word. It's the opposite of crisp writing. You mean somewhat similar to the programming language the same person developed?
- smhenderson 10y agoI find Stoustrop's writing quite the opposite, concise, informative and a touch entertaining at moments. But I can understand why you might see it otherwise, to each his own. You may find his book "Principles and Practice Using C++" [1] more accessible. [1] http://www.stroustrup.com/programming.html http://www.stroustrup.com/programming.html
- pjmlp 10y agoMaybe I suffer from Stockholm syndrome since I read all Bjarne's books, but I really like the book, to the point of having multiple editions of it.
- drharby 10y agoBjarne's text is just that, a text, not a read. It should be referred to as a reference. I completely agree with all your accounts because I did EXACTLY what you did a few years ago. I'm still working through the book, but I kinda said "eph it" and enrolled in a solid course. Worth the G I spent? absolutely. THat said, the 'effective' and 'Exceptional' books are well written.
- RotsiserMho 10y agoThat's his reference book. It's not designed for systematic learning. It's designed as a reference, as in "cut-and-paste stuff". You want one of his other books, meant to take you from zero to literate in not just C++11 but programming in general: https://www.amazon.com/Programming-Principles-Practice-Using-2nd/dp/0321992784 https://www.amazon.com/Programming-Principles-Practice-Using...
- emmelaich 10y agoI think you'd like Accelerated C++ by Koenig and Moo. It's by far my favourite C++ book and it's nice and short. One drawback may be it's age; it's 17 years old. On the other hand it was way ahead of it's time and good writing doesn't get old. (ps. I quite like Stroustrup's books but to each their own)