Discuss Scratch

card100
Scratcher
1000+ posts

C to C+ to C++

I was wondering if you could code something in C and then claim it's C++ or C+. I get that you could not really do the other way but I was wondering if you could do that one way transfer. Thanks!

-card100
ChocolatePi
Scratcher
1000+ posts

C to C+ to C++

There is no C+, only C and C++. For the most part, you could write something in C and it would compile in C++, but there are some tricky cases.
bobbybee
Scratcher
1000+ posts

C to C+ to C++

ChocolatePi wrote:

There is no C+, only C and C++. For the most part, you could write something in C and it would compile in C++, but there are some tricky cases.
Yeah, C++ at one point was a C deriviative, but nowadays they're distinct languages with distinct syntax.

So, many trivial C programs are valid C++ programs, but it's still a subset.

“Ooo, can I call you Señorita Bee?” ~Chibi-Matoran
card100
Scratcher
1000+ posts

C to C+ to C++

Oh, Ok…

Thanks

-card100

Powered by DjangoBB

Standard | Mobile