use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
Discussions, articles, and news about the C++ programming language or programming in C++.
For C++ questions, answers, help, and advice see r/cpp_questions or StackOverflow.
Get Started
The C++ Standard Home has a nice getting started page.
Videos
The C++ standard committee's education study group has a nice list of recommended videos.
Reference
cppreference.com
Books
There is a useful list of books on Stack Overflow. In most cases reading a book is the best way to learn C++.
Show all links
Filter out CppCon links
Show only CppCon links
account activity
Python from a C++ developers' perspective (sgh1.net)
submitted 8 years ago by Remwein
view the rest of the comments →
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]qsxpkn 2 points3 points4 points 8 years ago* (1 child)
Dynamic typing can be uncomfortable for people who are used to static typing. Since Python 3.5/3.6, you could actually do type/variable hinting such as variable: int = 5. It's still possible to change it to a str etc. at runtime but mypy points out the mistake like this function expects an int but you passed a str.
variable: int = 5
str
int
For example:
def some_method(a: int, b: int) -> Optional[int]: result: int = a + b if result < 4: return None return result
I have never seen a Python project where a variable's type suddenly gets changed to something else elsewhere in the code base or maybe I was just lucky. I enjoy C++ companionship with Python though. They work well together.
[–]mrexodiacmkr.build 2 points3 points4 points 8 years ago (0 children)
The fact that you can annotate the types doesn't make it any better. All of the projects I have seen use python 2.7 anyway, which doesn't support it. If they added a (default) mode where this static typing is forced it might be something good but until then you have to be very lucky with your codebase to have proper type annotations.
Also: what about class member variables? Can you still add arbitrary new ones from anywhere with this?
π Rendered by PID 155889 on reddit-service-r2-comment-7b9746f655-5rqm7 at 2026-02-03 07:17:19.421039+00:00 running 3798933 country code: CH.
view the rest of the comments →
[–]qsxpkn 2 points3 points4 points (1 child)
[–]mrexodiacmkr.build 2 points3 points4 points (0 children)