Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I primarily work in C++. My question is, for a C++ developer, what languages are beneficial to learn, from a job-profile point of view. For example, I see a lot of work combining C++ and Php these days. Conversely, I don't see a lot of work combining Ruby and C++ (unfortunately).

Of course, learning another language is beneficial regardless of whether it compliments a language.

share|improve this question

closed as off-topic by GrandmasterB, CodesInChaos, gnat, Jules, Ixrec May 31 at 3:55

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "Questions asking us to find or recommend tools, libraries, programming languages, resources (including books, blogs, tutorials, and examples), or projects to undertake are off-topic on Programmers as they attract opinionated answers that won't have lasting value to others. You may be able to get help in The Whiteboard, our chat room." – GrandmasterB, CodesInChaos, gnat, Ixrec
If this question can be reworded to fit the rules in the help center, please edit the question.

I learned MATLAB before I learn C++, and I thought C++ was a good way to optimize key parts of an algorithm originally prototyped in MATLAB. – rwong Oct 7 '10 at 14:51
It completely depends on what kind of work you want to do! C++ is good for hardware, drivers, and operating systems. A good compliment would be assembly if that's the work you want to keep doing, but I sort of doubt that or you'd already be doing it. Why not take this excellent free course: to help you decide? Just don't judge OOP based on Ruby. Kotlin is my favorite OOP lang these days. – GlenPeterson May 31 at 20:18

10 Answers 10

up vote 8 down vote accepted

I'd vote for Python or Ruby. C++ is The Language for doing as much as possible statically at compile time. Learning Python or Ruby will teach you how to think in terms of doing things dynamically at runtime. I'm in a similar situation, using D and Python as my primary languages. D's template metaprogramming is much more powerful than C++'s, but it's still all at compile time. Python's metaprogramming and reflection is all at runtime. It's a very useful combination because often there are idioms that are useful in both languages, but are more obvious in one than the other. Therefore, my D experience makes me a better Python programmer and vice-versa.

On another note, Python and C++ complement each other in that C++ is good at performance and bad at programmer productivity, where Python is just the opposite. If you learn both, you'll have mastered both ends of the spectrum on this tradeoff.

share|improve this answer
Python and C++ are even more complementary when you address the issue mentioned in the 2nd paragraph (performance) by embedding one into the other. It's not only straightforward (with e.g. Swig or Boost.Python) but also very rewarding. Being able to build a fully-featured C++ based Python extension module is certainly a line in your technical CV. – Tibo May 30 at 6:50

I think PHP compliments C++ nicely. In both cases, you're scraping the bottom of the barrel of languages, but PHP has so many annoyances that it makes C++ look like a diamond in comparison.

As far as languages that complement C++, I'm not sure.

share|improve this answer
Nicely spotted - I never knew that little English language nuance existed. Fixed. – MM01 Oct 7 '10 at 15:00
+1 for being a smartypants! – Frank Shearar Oct 7 '10 at 15:04
English is a good language for it;) "Oh! C++ is so dashing!" – Matt Ellen Oct 7 '10 at 15:20
I disagree that C++ is "scraping the bottom of the barrel," (I have a much higher view of the language) but otherwise agree that PHP makes it shine in comparison. +1 for snark. :) – greyfade Oct 7 '10 at 16:18
You have made my day... – ChaosPandion Oct 7 '10 at 16:32


I recommend Erlang. C++ is mostly used for performance, but it doesn't have great support for large scale concurrency. With that in mind Elrang would be a great complement since it has great concurrency performance but not very good performance for number crunching. Erlang is often used together with C/C++ in distributed and embedded systems, specially in telecom. Erlang is good support for interfacing with C&C++.

share|improve this answer

Python is often used in combination with C++ for file manipulation (and c++ code generation) and embedded scripting.

share|improve this answer

It does depend a little upon the platforms you are supporting, but if Windows is a platform, learning C# and the related techologies should keep you employeed for some time.

share|improve this answer
C# really does compliment C++ well. We use C++ for libraries that need to be fast, and leverage C# and the .Net framework to make it easy to write a modern UI around it. – RubberDuck May 30 at 12:09

C++: a kitchen-sink language, statically and manifestly typed.

Sounds like a good complement would be a language with a very few concepts, dynamically and latently typed. Sounds like Smalltalk!

share|improve this answer
  • Shell/Bash scripting I see is a great thing to have in your tool belt.
  • PHP as you said is a good one.
  • C programming is also fair game as far as I am concerned.
share|improve this answer

F# It's a functional language, statically/strongly typed but with type inference. You can use OO-style if you wish. Has a REPL for quick prototyping/scripting, type providers to access all kinds of data, pattern matching, easy async, parallel, and agent based computations.

share|improve this answer

It depends, what problems do you need to solve to accomplish your main objective: delivering software?

For me, knowing Labview lets me maintain and extend our real-time data collection tools. These produce a lot of raw data, so having a scripting language to parse and reduce it is extremely useful. I use Ruby.

Batch and/or shell scripting can also come in quite handy.

share|improve this answer

Node.js supports C++ addons. With the attention REST and microservices have been getting lately Node.js and JavaScript would be great addition to the language arsenal of a C++ programmer (if you don't like dynamic languages, there's a superset of JavaScript offering type checking called TypeScript.

Although C++ is not used very often in combination with Node.js, it can be easily integrated.

share|improve this answer

protected by gnat May 30 at 9:55

Thank you for your interest in this question. Because it has attracted low-quality or spam answers that had to be removed, posting an answer now requires 10 reputation on this site (the association bonus does not count).

Would you like to answer one of these unanswered questions instead?

Not the answer you're looking for? Browse other questions tagged or ask your own question.