Is C/C++ one language or two languages? I heard C++ was just C with classes. Is that right?
C++ diverged from C in 1982-1983, and that's a long time in computer years. But, there are many C libraries with C++ compatibility, including the C standard library itself, and a steady stream of programs are ported across from C to C++. Many C programmers only know or use the features that are compatible with C++.
They are defined by different ISO standards from separate committees. Even when they define compatible features, it is often defined in different terms.
Referring to C/C++ is about as valid as referring to Italian/Spanish. You should be careful to whom and when you use such a term. But it's true that there is diffusion of ideas in both directions, and the similarities are more than coincidence.
"C/C++" is precisely zero languages. It does not exist.
On the other hand, C is a language.
C++ is another language, which is kind of like C but also has classes and lots of other differences.
To be clear, @Zoidberg was spot on:
C and C++ are two completely different languages. C with Classes was the predecessor of C++, but the term is still often used for non-modern C++ (e.g. that uses raw pointers all over the place).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With