View Full Version : C++ or C# ???
Ronald McDonald
01-01-2005, 03:27 PM
I need to learn a object-oriented programming language and I need to choose between C++ and C#.
I don't have any experience in either one.
Which one is the best choice and why?
EDIT: Regardless of having to use .NET or not.
Kevin Wolff
01-01-2005, 03:40 PM
AFAIK, C# is only used with .NET. If you don't want/need to use .NET, then C++ is better. That's really all I know, though. http://forums.3drealms.com/ubbthreads/images/graemlins/redface.gif
KillerByte
01-01-2005, 04:13 PM
It really does depend on what you want to do with the language.
C# is better for distributed object computing where you wish to build client/server architecture. However, C++ may be better for teaching you the basics of programming and is more suited to other applications and games.
Ronald McDonald
01-01-2005, 08:43 PM
TY
I think I will go with C++ than.
I still have one question.
With Visual studio 2003 .NET you can create a C++ application. When the application is finished, do you need to have the .NET framework installed to run the C++ application which is made with Visual Studio 2003 .NET?
Sir Lemonhead
01-01-2005, 11:05 PM
Not 100% about .Net related things, but..
Half Life 2 was made using 2003.Net
No you can create normal c++ programs with 2003.net i'm sure.
Vasyl
01-02-2005, 12:09 PM
Ronald McDonald said:
When the application is finished, do you need to have the .NET framework installed to run the C++ application which is made with Visual Studio 2003 .NET?
If your code is using the new c++ .NET, with managed extensions and all that mess with the CLR, then the end user will need the framework installed.
You can still write standard c++ console and win32 programs however. Those don't require the framework.
http://www.mindcracker.com/VC70/VC7Intro.asp
AlienAssKicker
01-02-2005, 08:15 PM
C# is a million times easier than C++. Development time of an application is greatly reduced when using C# instead of C++.
I would choose C# over C++ anytime, when possible and wise of course.
And if you can choose JAVA, even better! http://forums.3drealms.com/ubbthreads/images/graemlins/grin.gif
PlayfulPuppy
01-03-2005, 02:57 AM
I'd say stick with C++. IMHO, C# should only be used by those that understand C++ and want to make their lives easier.
Doing the switch from C# to C++ would be a lot harder, because you'd have to get used to all of the idiosyncrasies and things that are 'missing'. Going from C++ to C# is a lot easier, because you can understand WHY things have been done the way that they have. This way you can learn your way in both fields, and be more adaptable to change.
Night Hacker
01-04-2005, 10:41 PM
You should stick with C++. Mainly because it isn't OS/Machine specific. You should always try and be portable when possible.
Learn C++. You can always learn C# down the road if you want/need to.
Drazula
01-05-2005, 04:12 PM
I agree with Night Hacker, with one caveat. If you need to build something soon and fast, learn C#. It is a true RAD tool. Also, you can run C# on Linux. (http://www.devchannel.org/devtoolschannel/04/04/16/1755236.shtml)
Kevin Wolff
01-05-2005, 07:37 PM
Drazula said:Also, you can run C# on Linux. (http://www.devchannel.org/devtoolschannel/04/04/16/1755236.shtml)
Unfortunately, Mono and .GNU don't work particularly well.
Night Hacker
01-06-2005, 12:30 AM
Drazula said:
I agree with Night Hacker, with one caveat. If you need to build something soon and fast, learn C#. It is a true RAD tool. Also, you can run C# on Linux. (http://www.devchannel.org/devtoolschannel/04/04/16/1755236.shtml)
A friend of mine has really said some nice things about C#, I would like to check it out, but I don't want to use a Microsoft compiler. If I can compile it with a free GNU compiler I would. I'm not sure if we can do that yet or not.
Joonas
01-06-2005, 07:01 AM
SharpDevelop can compile... and it's free.
Drazula
01-06-2005, 01:06 PM
I would like to check it out, but I don't want to use a Microsoft compiler.
Borland C# Builder. http://forums.3drealms.com/ubbthreads/images/graemlins/smile.gif
DudeMiester
01-07-2005, 02:39 AM
I say C++, although personally I don't know of any truely great languages. C++ is very good, certainly better then C#, but not perfect. I wouldn't even put it close to perfect, but it is universal.
Geo-King
02-02-2005, 12:23 AM
Good free compiler.
http://www.bloodshed.net/devcpp.html
Night Hacker
02-02-2005, 02:31 AM
Geo-King said:
Good free compiler.
http://www.bloodshed.net/devcpp.html
I'll second that. I use Dev-CPP (have been for a few years now) and love it. It can import most Visual C++ projects as well just not .NET stuff yet. Although setting up a project manually from a .NET to Dev-C++ is pretty simple. I recently converted one of the NeHe opengl demos (lesson 46 (http://nehe.gamedev.net/data/lessons/lesson.asp?lesson=46), see credits at the bottom http://forums.3drealms.com/ubbthreads/images/graemlins/smile.gif) to Dev-C++. Didn't take long.
Ronald McDonald
02-02-2005, 02:00 PM
I use the Borland compiler 5.5
The funny thing is, it creates .exe files and MS Visual Studio does not http://forums.3drealms.com/ubbthreads/images/graemlins/confused.gif
CronoMan
02-03-2005, 06:12 AM
Ronald McDonald said:
I use the Borland compiler 5.5
The funny thing is, it creates .exe files and MS Visual Studio does not http://forums.3drealms.com/ubbthreads/images/graemlins/confused.gif
What do you mean?
Well, Visual Basic 6.0 does not make .exe files unless you click file->Make EXE, but VB.NET makes exe files,
and any MS VC++ makes exe files...
btw; the borland IDE sucks donkey. http://forums.3drealms.com/ubbthreads/images/graemlins/smile.gif
Ronald McDonald
02-05-2005, 09:31 AM
What compiler do you prefer than?
CronoMan
02-07-2005, 03:00 AM
I prefer the MS VC++.NET http://forums.3drealms.com/ubbthreads/images/graemlins/smile.gif
And it has an excellent IDE with IntelliSense and alot more. And the precompiled headers are lifesavers http://forums.3drealms.com/ubbthreads/images/graemlins/smile.gif
Well, the Borland compiler isn't bad, but the IDE is kind of... well, annoying sometimes.
Ronald McDonald
02-07-2005, 07:06 AM
It's best for me not to get too familiar with any of the IDE's since I have to learn to make everything myself in my next education http://forums.3drealms.com/ubbthreads/images/graemlins/frown.gif
Destroyer
02-09-2005, 01:46 AM
C then C++. I think its better to learn C first then C++ then c#
DudeMiester
02-09-2005, 08:14 PM
I disagree, C++ is a superset of C anyways, so learn C++ and you know both. Just starting coding C++, and just start simple. You don't have to learn template metaprogramming, functors and polymorphic multipule inheritance first, lol! You can just do simple procedural code, barely different then the basic stuff you would do in Java or C# or C.
Night Hacker
02-09-2005, 10:38 PM
Destroyer said:
C then C++. I think its better to learn C first then C++ then c#
Agreed. I haven't bothered with C# yet and I still do alot of C coding.
Ronald McDonald
02-13-2005, 09:55 AM
You guys confuse me http://forums.3drealms.com/ubbthreads/images/graemlins/doh.gif
Kristian Joensen
02-13-2005, 10:09 AM
DudeMiester said:
I disagree, C++ is a superset of C anyways, so learn C++ and you know both. Just starting coding C++, and just start simple. You don't have to learn template metaprogramming, functors and polymorphic multipule inheritance first, lol! You can just do simple procedural code, barely different then the basic stuff you would do in Java or C# or C.
Given the choice between c, c++ and c# I definetly agree wtih you DudeMiester but I would defenitly prefer Delphi or Free Pascal over any of the c based languages anytime.
Both c++ and c# are easier than c becuase they are object oriented, I find c# code much easier to read though.
Alive
02-13-2005, 04:32 PM
Well there's not that much of a choise because both languages are kind of a bitch. At first glance they are sweet and shiny but if you dig deeper and deeper you'll realize that it doesn't really matter much which one you take.
Also being able to program in a language doesn't mean that you can program. If you can program you can choose any language and thus it doesn't really matter which language you chose first (besides the fact that some teach really shitty programming and make it hard to program clean).
So choose any of them you will be doomed in some way.
Destroyer
02-16-2005, 01:28 AM
DudeMiester said:
I disagree, C++ is a superset of C anyways, so learn C++ and you know both. Just starting coding C++, and just start simple. You don't have to learn template metaprogramming, functors and polymorphic multipule inheritance first, lol! You can just do simple procedural code, barely different then the basic stuff you would do in Java or C# or C.
no I think its easier to move from C to C++ then from C++ to C. SO learn C first then C++ then C#(I still havent even touched C#)
DudeMiester
02-16-2005, 07:31 PM
I don't your point, plus you have no reasoning to back it up. Like I said in C++ you can code essentially in C, and then try out C++ features as you become comfortable. There is no need to jump right into classes and all that with C++. Plus, the compiler he will use will do C++ anyways, so he's going to use C++ features without knowing it most likely.
Night Hacker
02-17-2005, 04:08 AM
DudeMiester said:
I don't your point, plus you have no reasoning to back it up.
He doesn't need any, it's called an opinion. And it differs from yours, I see no need to argue the point with him. You stated your preference, as did I, now he is. Deal with it.
Theseus314
02-17-2005, 09:41 AM
DudeMiester said:
I don't your point, plus you have no reasoning to back it up. Like I said in C++ you can code essentially in C, and then try out C++ features as you become comfortable. There is no need to jump right into classes and all that with C++. Plus, the compiler he will use will do C++ anyways, so he's going to use C++ features without knowing it most likely.
Whilst it's true the C++ contains all of C, what you forget is that both languages are coded with differing styles. Personally I've learned a very OOP method of working C using entirely ADTs, which if you learned C++ first would never be encounted because these concepts are primary features of the language.
Also, there isn't a standard for C++ libraries, so if you want to work with multiple slightly exotic platforms, or something fun like renderware (you can write a C++ wrapper to interface with it though), you are going to be wanting to use C.
Destroyer
02-20-2005, 01:42 AM
Night Hacker said:
DudeMiester said:
I don't your point, plus you have no reasoning to back it up.
He doesn't need any, it's called an opinion. And it differs from yours, I see no need to argue the point with him. You stated your preference, as did I, now he is. Deal with it.
Thank You. The reason I feel like C is a better choice to start with is because thats how I did it and it made sense to me, and I recommend it to others. http://forums.3drealms.com/ubbthreads/images/graemlins/smile.gif
DudeMiester
02-20-2005, 02:40 AM
No, mere opinions are useless in a thread like this. In any case you should know how and why it worked for you. This guy wants to know where to start, and do to that sure he needs a list of options, but he also needs reasons for them. Otherwise, how is he to choose which option to take? If he has no reasons then that option might as well not exist at all.
Anyways, as for codeing style, I would say C is detrimental. OOP is simply a better programming model. It allows for all the possibilities of procedural and much more. Thus, he should start with a language that offers the greatest breadth. He should only deal with at first those areas that immediatly concern him, that is the procedual aspects and raw logic of the language. Then once he has mastered that move on to higher concepts. With C you simply hit wall where you can no longer progress, and unless you have previous knowledge you may not even know there is a wall. Experimentation is critial to effective learning, at least in programming, and thus to learn in an environment with artificial constraints will equally constrain and inhibit your learning process.
Night Hacker
02-20-2005, 03:10 AM
IN YOUR OPINION.
DudeMiester
02-20-2005, 05:26 PM
Night Hacker said:
IN YOUR OPINION WITH REASONING.
Fixed. http://forums.3drealms.com/ubbthreads/images/graemlins/wink.gif
Night Hacker
02-21-2005, 03:32 AM
So if our [u]opinion</u> doesn't agree with you, we're being unreasonable? How very arrogent of you.
MentalSentinel
02-21-2005, 12:44 PM
no I think its easier to move from C to C++ then from C++ to C. SO learn C first then C++ then C#(I still havent even touched C#)
Well Stroustrup and other C++ experts say it's best to learn C++ first.
I can't tell, i never touched C, started with C++, luckily. http://forums.3drealms.com/ubbthreads/images/graemlins/wink.gif
DudeMiester
02-21-2005, 09:58 PM
Night Hacker said:
So if our [u]opinion</u> doesn't agree with you, we're being unreasonable? How very arrogent of you.
Only if you don't provide your own counter-reasoning. Then yes, it is unreasonable for anyone to care about what you say, or do consider your post helpful. How can you help them if you don't explain yourself? If you don't answer the why?
Kristian Joensen
02-22-2005, 06:24 PM
sentinel said:
no I think its easier to move from C to C++ then from C++ to C. SO learn C first then C++ then C#(I still havent even touched C#)
Well Stroustrup and other C++ experts say it's best to learn C++ first.
I can't tell, i never touched C, started with C++, luckily. http://forums.3drealms.com/ubbthreads/images/graemlins/wink.gif
Isn't Stroustrup biased ?
He created C++ after all !!!.
You couldn't be more biased.
Night Hacker
02-23-2005, 06:28 PM
My reasoning? I've been programming (using computers in fact) longer than you've been alive. Experience is my reasoning.
DudeMiester
02-23-2005, 10:40 PM
And what do those experiances consist of? That is, what blunders do people make when they start from C++ and not C?
Night Hacker
02-25-2005, 04:05 AM
Sheesh, this is just like the religious thread! You believe in C++ first, I believe in C. Nothing I say will convince you so I'm not going to bother trying.
I posted my opinion to help someone, not to argue and nitpick with you.
AlienAssKicker
02-25-2005, 02:48 PM
It's not about opinion, it's about silly C/C++/C# programmers not embracing the magnificence and greatness of JAVA. http://forums.3drealms.com/ubbthreads/images/graemlins/grin.gif
Open your heart to JAVA, our saviour.
Hail to the Virtual Machine!
Now if only it go be faster, it would be perfect http://forums.3drealms.com/ubbthreads/images/graemlins/wink.gif
DudeMiester
02-25-2005, 09:55 PM
I would whore myself to MicroShaft and it's debacle of C# before I touch the bizzare fetish that is Java. http://forums.3drealms.com/ubbthreads/images/graemlins/tongue.gif
C++ 0\/\/|\|$ j00!
Destroyer
02-26-2005, 02:44 AM
ya im not much into learning JAVA, but one of these days I will just so I can say I know JAVA.
Ecmaster76
03-13-2005, 02:12 AM
JAVA is pretty slick to program, but not particularly useful on x86 hardware. Most people can't even run the stuff you make, since Windows doesn't ship with a VM anymore. And its kinda slow.
I have to say that the online documentation (Sun) for JAVA is exceedingly well done. I used it almost exclusively in my CS class and rarely used the book, except when our assignment was nearly identical to an example.
Am half-ass-edly learning C++. I am using the DEV 4.9.9.2 and it seems really good. I like the update feature and the interface reminds me a fair amount of JCreator, which I like a lot more than any other JAVA ide I tried.
CronoMan
04-26-2005, 05:38 AM
I don't really like Java.
It's bad structured, and it seems like they didn't put much time into planning.
I prefer C# for GUI applications, and C++ for non-GUI applications.
C# is superior to Java. If you haven't tried it, you should.
You'll find it very practical, and it's much more efficient than Java too. The only thing Java has that C# sadly does not, is applets. Applets are a stroke of genius.
vBulletin® v3.8.7, Copyright ©2000-2012, vBulletin Solutions, Inc.