Top products from r/Cplusplus
We found 32 product mentions on r/Cplusplus. We ranked the 33 resulting products by number of redditors who mentioned them. Here are the top 20.
1. Programming: Principles and Practice Using C++ (2nd Edition)
Sentiment score: 4
Number of reviews: 5
2. C++ Primer (5th Edition)
Sentiment score: 1
Number of reviews: 4
Addison-Wesley Professional
3. Accelerated C++: Practical Programming by Example
Sentiment score: 2
Number of reviews: 2
Addison-Wesley Professional
4. Effective Modern C++: 42 Specific Ways to Improve Your Use of C++11 and C++14
Sentiment score: 2
Number of reviews: 2
O'Reilly Media
5. A Tour of C++ (C++ In-Depth Series)
Sentiment score: 1
Number of reviews: 2
Used Book in Good Condition
6. C++ How to Program
Sentiment score: 0
Number of reviews: 1
Author Harvey Deitel, Paul DeitelNumber Of Pages 1104 pagesFormat Paperback
7. Absolute C++, Student Value Edition (5th Edition)
Sentiment score: 1
Number of reviews: 1
Computer ScienceC++
9. A Tour of C++ (2nd Edition) (C++ In-Depth Series)
Sentiment score: 1
Number of reviews: 1
10. Design Patterns: Elements of Reusable Object-Oriented Software
Sentiment score: 1
Number of reviews: 1
Great product!
11. Computer Architecture: A Quantitative Approach
Sentiment score: 1
Number of reviews: 1
13. Effective C++: 55 Specific Ways to Improve Your Programs and Designs (Professional Computing)
Sentiment score: 1
Number of reviews: 1
Addison-Wesley Professional
14. The C++ Programming Language, 4th Edition
Sentiment score: 1
Number of reviews: 1
100% Satisfaction Guarantee. Tracking provided on most orders. Buy with Confidence!A brand-new, unused, unopened item in its original packaging, with all original packaging materials included.High seller positive feedback for the seller!Lowest price on amazon!
15. Starting Out With C++: From Control Structures Through Objects
Sentiment score: 1
Number of reviews: 1
16. C++ Primer Plus (6th Edition) (Developer's Library)
Sentiment score: 0
Number of reviews: 1
100% Satisfaction Guarantee. Tracking provided on most orders. Buy with Confidence!A brand-new, unused, unopened item in its original packaging, with all original packaging materials included.High seller positive feedback for the seller!Lowest price on amazon!
> Thanks for the comprehensive reply.
No problem.
> I'm already familiar with the basics of computer architecture, although I could certainly stand to know more. If you know of any good medium-level textbooks on that, I'd appreciate it.
I learned computer architectures using this book (but with an earlier edition): http://www.amazon.com/Computer-Architecture-Fifth-Edition-Quantitative/dp/012383872X. I think this is the same book they use in MIT.
> I realize that this is the case notionally, but I've come across posts in various places on the internet that claim compiler optimizers will sometimes inline recursive functions up to some arbitrary compiler-dependent depth so that a single stack creation can handle a recursion depth up to that arbitrary count, making the performance difference between recursion and iteration much less significant for relatively small scales. Then there's also tail recursion optimization where the recursion can go arbitrarily deep without needing to increase the stack.
You said it yourself twice:
That is the thing, because it is arbitrary, the only way you will be able to tell is to look at the compiled code and check if the recursion/iterative loop was optimized as you expect it to. Compilers have many levels of optimization. There is compile time optimization, which we are all familiar with. There is also link time optimization where optimization happens during link stage. There is also a technique performed by LLVM where the compiler creates an intermediate language bit code then perform optimization during link time based on the generated bit code. I am sure there are other optimization stages/techniques that exist on other compilers. These different levels of optimization stages use varying criteria to judge how a code will be optimized. You will need to check the resulting binary, using the optimization switches of your choice, whether the compiler's technique is used or not.
> The problem is that I don't have any authoritative sources on any of these optimizer techniques, so there might be lots of useful tricks that I'm not exploiting.
To be honest, many of these things are learned more through experience. You are on the right track on being curious about what the compiler does (or specifically, how it optimizes code), but in most cases, you will probably learn them through your own experiments (e.g. getting curious about whether solution y works better than solution x, then doing it, and then profiling and verifying through the internet forums).
> So I guess compiler documentation is where I need to look to find these things out?
Cannot say that it isn't, but I doubt compiler manuals/documentation will talk about these things in detail. It is your best bet, but most likely, you will have to go through the source code of the compiler (if it is open source), or find some white papers talking about how such optimizations are achieved by the said compiler.
SFML Game Development
SFML Game development is super straight forward and simple, this book does a good job of breaking down some of the concepts you will learn in the other book I've listed and applying them with c++ and sfml. Having started with SDL and using both SFML and SDL extensively, SFML is definitely my favorite of the two.
Game Programming Patterns
Does a great job of explaining many of the common programming patterns used in and outside of game development, and it's a great piece to read if you're still conceptualizing how certain modules in your game will function at a high level.
Both are excellent books, and I believe will get you what you are wanting to learn.
Edit: Both books are written for those without extensive knowledge of their topics, the SFML book is written for much more novice c++ programmers, and the Patterns book is written for those with a little more experience. Even if you're familiar with many programming patterns, I'd consider the second book a great refresher course.
Scott Meyers is good -- check out Effective Modern C++. He has a training course, Overview of the New C++ -- I haven't taken it, but I've seen enough of his stuff to recommend him.
If you want more introductory C++ stuff, look at some of the online courses by Kate Gregory (some free trials available -- which might be good to assess if it's what you're looking for).
Once you get going, I'd recommend Sutter's Mill. In particular, check out his "Elements of Modern C++ style". There are also loads of videos online from CppCon (just google it).
But keep in mind that one limiting factor in your request is the "for C programmers" part. A big part of recent evolution of C++ has been getting rid of the need for core C features like pointers. By keeping the C angle, you may be anchoring yourself to the past.
And if you want to go that route anyway (ie keep the C angle), then there is less harm including some older stuff too. I really liked Bruce Eckel's Thinking in C++, which you can find online for free (it isn't quite ancient or modern).
Ok. I would probably recommend A Tour of C++. It is a short book because it doesn't go on and on about stuff you already know, but is still friendly to C++ beginners.
EDIT: Read the description here <https://www.amazon.com/Tour-2nd-Depth-Bjarne-Stroustrup/dp/0134997832/ref=sr_1_1?ie=UTF8&amp;qid=1527540269&amp;sr=8-1&amp;keywords=a+tour+of+C%2B%2B&gt; and see if it describes what you want.
In particular:
> This guide does not aim to teach you how to program (for that, see Stroustrup’s Programming: Principles and Practice Using C++, Second Edition), nor will it be the only resource you’ll need for C++ mastery (for that, see Stroustrup’s The C++ Programming Language, Fourth Edition, and recommended online sources). If, however, you are a C or C++ programmer wanting greater familiarity with the current C++ language, or a programmer versed in another language wishing to gain an accurate picture of the nature and benefits of modern C++, you can’t find a shorter or simpler introduction than this tour provides.
If you aren’t very familiar with C++, my advice would be to admit it at the outset. Modern C++ is a huge, complicated (and often convoluted) language and they will be able to poke holes in your seeming expertise unless you admit it at the outset. I’ve interviewed people who claim to be a 9 out of 10, but if that is the case you should probably know most of the standard by heart.
That out of the way, I would say that Bjarne’s “Tour of C++” is a great read that can easily be done in a week (I did and I wasn’t cramming for an interview). It gives a nice introduction to modern C++ features for a well-versed programmer coming from another language:
https://www.amazon.de/Tour-C-Depth/dp/0321958314
That's a good answer. I'm so sick of all this "C++ is too hard as a first language" stuff I see everywhere. I learned C++ as my first language and it taught me how programming actually works. If you learned py thing first sure you could program easy, but you wouldn't have as strong a foundation on how your computer works. This book is what I used to learn, it will teach you most of what you need. It's a great book, one of the few textbooks I would would actually recommend. It assumes your starting out with C++ as your first intro to programming so it's perfect for you. Good luck
Posting this as a top level comment so people can see this without digging. Here are some of the resources I have used plus additional ones I've found that may be useful:
Sorry but there's no cheat sheet and no reasonable way of making one. C++ is a rather large and complex language laid atop C, which is effectively laid atop an assembly language, which is compiler manufacturer and target platform dependant.
The best way to learn C++, or any programming language for that matter, is to use it, learn from your mistakes, and of course researching and reading everything you can. And of course, have fun with it!
Many popular books exist covering C++ things. Here are a couple good starter ones, in my opinion:
A couple popular C++ sites:
If you're simply starting to learn programming, start small. I suggest beginning with an object-oriented scripting language like Ruby, Python or Javascript. Most concepts will transfer to C++, but beware that the syntax will not - you will quickly see the difference!
I started teaching myself C++ by following these video tutorials (and stopped after the book I ordered arrived). I found them pretty easy to follow. I've stumbled across plenty of other video series on YouTube during my travels too - maybe see what's out there, pick one and follow :-)
Also, this thread on StackOverflow recommends this book (Programming: Principles and Practice Using C++ (2nd Edition) for non-programmers who want to learn C++. I think paying for a book is not a bad idea, as the material will be put together thoughtfully and presented in a logical way.
C++ is not the most beginner-friendly of languages. If you find it too tricky once you start learning, there's no shame in putting it aside for now, learning something easier to begin with and coming back to it later. I've heard Python is a great language for beginners, and is used in the real world so it's not like you'll just be learning a "language for beginners" - you'll be learning a "real" language just like C++.
I was also first a C programmer and only started learning cpp later. I have found this book to be excellent:
Accelerated Cpp book
it is intended to complete novices, which you are not. However I think it is still perfect for you because I think that it introduces Cpp the way it should be and not as a C extension. After you are comfortable with the std I would suggest you move to good practices books (effective c++ etc) and/or design patterns books
Here's the thing: learning any language takes practice: fingers on the keyboard, brain engaged in solving problems. Any other resource that you use, whether books, classes, or whatever, will only be a guide to show you what and how to practice.
So ask yourself: when you tried learning with a book, did you do it sitting in front of a keyboard with an IDE up, and actually do the hands-on sections or the examples in the book? If you did and still had trouble, then sure, an MIT Open Courseware class might help you: maybe you just learn in a different way.
I myself learned Python partly by going through the MIT Intro to Programming OCW, and found it be a great resource. By contrast, I learned C++ by working through this book. In both cases, though, I had to actually do the homework, work my way through the practice problems, and get the hands-on time, in order to become comfortable with the language.
So, TL;DR: it depends entirely on whether you're willing to commit to putting in the work to practice.
If good is the priority, I recommend going straight to the source -- the guy who invented the language, Bjarne Stroustrup. You can buy it new for $35, or head to your local library and borrow it for free.
Thanks! I've worked with amateur JavaScript before (my first language), so my natural formatting might be off.
Also, I hate using goto but I haven't nailed down Classes and Headers. I got myself stuck and ended up using it anyway. My C++ teacher (who I only had for about 2 weeks at a "camp".) didn't go to in-depth about it so I'm kinda lost in some areas.
Thankfully, I have copies of this and this in iBooks on my iPod for reading in my spare time.
The commented "Signature" was where I built the design of what would be outputted, and is not any actual "Signature."
It's nice to get so much feedback from what I thought looked like a dead thread. :)
Thanks /r/Cplusplus!
*Edited for grammar.
I'll repeat what /u/Transputer said: You need a book.
Especially since you are learning C++ from scratch and it's your first language.
This book is written by the creator of the language, it's recently updated to cover the new additions by the C++11 and C++14 standard.
It's designed to teach first year university students programming in C++
http://www.amazon.com/Programming-Principles-Practice-Using-2nd/dp/0321992784/
Your other option is to learn Programming through another language that might have video lectures or tutorials (Java?) once you are familiar with the concepts you can pick up a smaller book and get acquianted with C++
Good luck.
ubuntu, cmake, gcc, learn about references, pointers and const correctness, these books: my favorite data structures book, and stupid simple tutorial book
edit: also, I've recently started using Visual Studio Code as an editor. Its pleasant to look at, is multi platform and gets rid of the normal nastiness that you'd normally have to deal with from real visual studio.
Stroustrup's book is considered (one of) the best for beginners. Lots of exercises in every chapter.
Link: https://www.amazon.com/Programming-Principles-Practice-Using-2nd/dp/0321992784
When/if you get to the point where you want to learn more about multithreading, this is a good resource.
I think you would enjoy Expert C Programming: Deep C Secrets. Note: the book was first published in 1994
The 5th edition isn't out yet (http://www.amazon.com/Primer-5th-Edition-Stanley-Lippman/dp/0321714113/ref=dp_ob_title_bk) and the 4th was released in 2005 (http://www.amazon.com/Primer-4th-Stanley-B-Lippman/dp/0201721481/ref=sr_1_4?s=books&amp;ie=UTF8&amp;qid=1343148370&amp;sr=1-4&amp;keywords=C%2B%2B+Primer+%285th+Edition%29) So i guess it's better to wait for the 2012 edition.
Program a simple game!
[This Roguelike tutorial] (http://codeumbra.eu/complete-roguelike-tutorial-using-c-and-libtcod-part-1-setting-up)
combined with this book
should do the trick. Both expect that you already have some programming experience, so you can jump right into useful learning techniques.
Yes sir:
http://www.amazon.com/Primer-Plus-6th-Developers-Library/dp/0321776402/
10/10 would recommend Programming Principles and Practices by Stroustrup
https://www.amazon.com/Programming-Principles-Practice-Using-2nd/dp/0321992784
It does not seem like a good resource to me. It assumes you already know a C-like language and it starts by complaining that C++ is an oversold language and we should all program in Basic. I am only exaggerating a little. It lacks the insight that people like Meyers, Sutter, Alexandrescu or Stroustrup provide. Better learn from the man himself: https://www.amazon.com/Tour-C-Depth/dp/0321958314
You might want to check out C++ Primer
> What's next?
I read plenty of websites to help out new or aspiring programmers, but this theme repeats like a thousand times and I just don't understand it. It's probably an issue with the system, but even then I still don't get why people are this way, it's as if they are not thinking...
Anyway. "What's next?" is immediately obvious to any rational person.
> I'm interested in making a game.
You do that. Tadaaa fucking done why did you even ask.
The problem is people are learning stuff for learning's sake. What the flying fuck? I just don't get it. You should learn stuff because you want to do something. You, OP, actually know what you want to do, making a game, so just... start? You will encounter plenty of problems along the way. You will research those problems and learn a huge amount.
If you notice you are lacking fundamental skills and just don't make any progress, read a fucking book. Have people forgotten that there are books on topics to learn those topics? I entirely taught myself C++ just by reading this, I have infos on how to get it if you want.
Also Go to StackOverflow and read the top 1000 questions (or how many you want).
There are so many resources on the internet... so many blogs to follow and read, so many tutorials to do.
I'm a little bit sorry that this is a rant, but I also included plenty of information so don't you fucking complain.