C++: What is it good for? – Part 1
First, a little bit of history. Back in the `50s, programmers would write machine code: a list of commands which the computer understands, but a human being – much less. This caused a lot of problems. The main one, in my opinion is: when entities speak in different languages, chances are they won’t understand each other 100%. And that is exactly what happened. A lot of failed serious bugs and failed projects occurred due to this.
So, efforts began to develop programming languages which are closer to the language that human beings speak (usually with English keywords). Some of these languages that were developed: Cobol, Fortran, LISP, SmallTalk, Basic, Pascal, C and of course C++.
However, there was always a paradox here: the closer the language is to humans, the more difficult it is for the computer to understand, and visa-versa. This brought about the following rule of thumb that still holds true today: if you need granular control of the computer, use a language which is closer to the computer’s; otherwise, use a language which is easier for you to “speak” in. As time went by, computers became more and more powerful, and more types of computer programs were able to get by without granular control of the computer. This caused a drift of the popular languages towards languages that are easier for humans to express themselves in.
C++ is much closer to the computer than to humans. C# and Java are easier for humans to interact with. That is the main reason why C# and Java are more successful than C++. However, this is not the whole story. More about this in my next article.