whats the diffference between c and c# and c++

Started by
10 comments, last by Oluseyi 17 years, 6 months ago
which one of those c's are the easiest to learn? what is best for game making?
Advertisement
Ignore me, I just realise this is the beginners forum.
C# rocks, all the rest of them suck!















... ok, kidding.

C is the oldest, its a procedural language. ( Aka, its built around the concept of functions ).

C++ is a quasi-Super set of C. It took most of what C did, and added objects on top of it.

C# is the newest, and least related. It requires a runtime on the target machine to run. Syntax wise, its a cross between C++ and Java.

Of those three, the easiest to learn is either C# or C. C is probrably easier to learn the basics of, as it has a very small library of functions you need to learn. That said, it doesnt hold your hand worth a damn, so you can really screw up. C# has a very good library of functions to go with it, that makes it a very productive language, once you figure out how to use that library. C++ is easily the hardest of those 3 to learn, unless your some kind of Idiot Savant type that thinks in C++ naturally.

Define best. Most common, definatly C++. Most productive, I would say C#. Supports most platforms C then C++. Most game libraries, C++.

As an example of productivity, I tend to be about 4 times more productive in C# then I am in C++. Then again, when I hit a wall, it tends to take me longer to figure the problem out.
Well the easiest language to learn and be productive with of the three mentioned would have to be C#(C Sharp). It is a managed language to an extent. Where as C and CPP both fully compile before use, C# uses a 'Just In Time' compilation. Meaning that once the end user runs it for the first time it compiles. This is actually benificial in some cases because it takes into account each individual users computer so it can better optimize itself. Sadly, C# programs will only run on Windows based systems and Xbox360. C and CPP on the otherhand will run on almost all platforms.

I would have to say that C# is the best bet for any beginner. I have been tinkering with it and in a matter of hours I was able to do things that would have taken me DAYS with CPP.

Also to note is that C# is not nearly as industry accepted for games as CPP. So learning CPP at some point will certainly make getting a job in the industry much easier. Hope that helps.
------------------This is so stupid!
Quote:Original post by -JetSirus-
Sadly, C# programs will only run on Windows based systems and Xbox360. C and CPP on the otherhand will run on almost all platforms.


Languages themselves are not bound to any one platform(or at least they shouldn't be). C# programs can run on Windows, Linux or Macs as long as they use Mono, but programs compiled using Microsofts compiler only run on windows. Libraries/APIs are also part of it since DirectX and WinForms(some has been ported though) only work on Windows. The same rules apply to C and C++ too, you can't make a C++ program in Visual C++ with DirectX and expect it to run on anything other than Windows.
These may provide some insights.

1) Professional Games Made In C#?
2) Java for game development?
3) Java----C/C++
4) c++ or c#
5) Question about Java Vs. C# Vs. C++
6) Java Games?
7) Java is fast?
8) Secondary Language:VB or Java?
9) What makes C++ so powerful?
10) C# games and cheating...
11) Is C# good enough for system utility programming
12) MC++ vs. C#
13) Which language is best for a 3d Games Engine?
14) C# vs C++ as a choice for development
15) Try out C# or stick with C++
16) Is Java the Future?
17) why C# and not Java?
SlimDX | Ventspace Blog | Twitter | Diverse teams make better games. I am currently hiring capable C++ engine developers in Baltimore, MD.
I just finished readin the first link that you posted there Promit, and it was so full of misinformation as to not be funny, mostly on the proC++ side.

Then again, any thread where you have a pro C++ or pro C# side, is mostly a waste of time to read. Zealots are idiots, regardless to their zealotry.

If I could offer one piece of advice, when reading the pro's of a language, read what the zealots have to say. When reading the con's of a different language, never listen to a zealot.
Why do we always get these threads all at once? :/

They're different languages that happen to share a common background. The best thing, if you're genuinely interested, is to learn what each one is, separately. If you're just trying to pick which one to use, and you haven't programmed before, there's a high probability that "none of the above" is correct.
Quote:Original post by Serapth
I just finished readin the first link that you posted there Promit, and it was so full of misinformation as to not be funny, mostly on the proC++ side.
I'm afraid the pattern continues throughout every thread. Very nearly none of the posters in any given thread know much about what they're talking about, and the ones who do are frequently drowned out.

I don't know what I'd do if I were someone who had to answer this question. I'm in the comfortable position of having used nearly every major language extensively on nearly every major desktop platform, so I had the chance to make up my own mind after a lot of experience.
SlimDX | Ventspace Blog | Twitter | Diverse teams make better games. I am currently hiring capable C++ engine developers in Baltimore, MD.
Thats one of the reasons im glad I started programming before the internet came into existance. I learned lots of things via trial and error, which probrably isnt the most efficent way to do it. However, I formed opinions based off my experience's not some annoymous internet "expert".

Generally now, the ones I tend to listen to are the pragmatists. If I detect a lot of emotion behind someones post, I generally regard it as tainted. ( See slashdot or many examples ;) ).

By the way, I noticed my ranking or rating just dropped about 30 points. I dont know why or how that works. Does your rating have any actual bearing in reality ( aka, if my rating goes to low, will I lose functionality?), or is it purely an ego thing?

This topic is closed to new replies.

Advertisement