Hello everyone,
In the online course I'm taking, the language of choice for the first 6 weeks is C. Before, I didn't have a very high opinion of C. I like object oriented programming, and the biggest thing turning me away from C was the fact that it's not object oriented. But in these several lesson, I have come to really like the power and freedom of C. Despite the arcane parts and ridiculous identifiers like fread, fprintf, and strlen that my screen reader reads weirdly, working with the full understanding about how you are doing something and how you're interacting with hardware--especially memory is rather satisfying. So I'm thinking of learning C++ in addition to C later as my main programming language to have both the power of C and object oriented features. The question is, what is exactly the relationship between C and C++? Would I be able to seamlessly switch between them? I mean, is the syntax of C++ identical to C only with object oriented parts added, or it's not the case?


Life is a game, but it seems that I have been sent straight to the final boss level. Lucky me.

Thumbs up


Generally it's just the object oriented programming. Of course there are some differences, but you should be able to run a C program with C ++ without rewriting the whole code.

Thumbs up +1


C came first, followed by C++ which is technically its own language. The biggest difference as Tagor mentioned is the Object Oriented Programming approach among other things. C++ is technically built on top of C's concepts, similar to Python, so you can usually run any C code in C++, but you can't run C++ features in C. The C language is oft considered quite lightweight and powerful, and still used pretty heavily these days for a variety of reasons such as for operating system development, compilers, etc.

-BrushTone v1.3.1: Accessible Paint Tool
-AudiMesh3D v1.0.0: Accessible 3D Model Viewer

Thumbs up +1


in a simple answer, c++ is c + object orianted, (if using C++11 lambdas and constexprs and other things) + some other standard things like  smart pointers, etc which are declared in the std namespace
also guys, operating systems can also be developed by using C++

bitcoin address: 1LyQ3hziMC2DTnCtgM3V1zfuZ73P3CYT9P

Thumbs up