C# or C++ ?

  • (2 Pages)
  • +
  • 1
  • 2

25 Replies - 6315 Views - Last Post: 04 August 2013 - 06:22 PM

#1 Yeronox  Icon User is offline

  • D.I.C Head

Reputation: 2
  • View blog
  • Posts: 102
  • Joined: 12-March 12

C# or C++ ?

Posted 13 March 2012 - 12:08 PM

So, I'm starting now and I'd like to know which one is better. I think that by learning one of them I could learn PHP faster, but because I'd like to study C++/C# and PHP, I'll start with... C++ or C#? And why you'd choose it :)
Is This A Good Question/Topic? 0
  • +

Replies To: C# or C++ ?

#2 macosxnerd101  Icon User is online

  • Self-Trained Economist
  • member icon




Reputation: 10573
  • View blog
  • Posts: 39,147
  • Joined: 27-December 08

Re: C# or C++ ?

Posted 13 March 2012 - 12:14 PM

We have some threads covering this you may find helpful in making your decision:
http://www.dreaminco...5705-c%23-vs-c/
http://www.dreaminco...me-programming/
Was This Post Helpful? 0
  • +
  • -

#3 Ryano121  Icon User is offline

  • D.I.C Lover
  • member icon

Reputation: 1362
  • View blog
  • Posts: 3,002
  • Joined: 30-January 11

Re: C# or C++ ?

Posted 13 March 2012 - 12:59 PM

We can all give our opinions but at the end of the day it boils down to which one YOU want to learn. If we said both of those languages suck (which they don't) and told you to go learn LOLCODE would you do it? Of course not.

OK its a bit of an extreme example, but it displays my point. If YOU don't like the look of a language then don't learn it. However if you like the look of another completely unrelated language, go learn that.

It's not always the case that you should learn the most helpful language (for now at least). It's the experience that counts. By learning either of those you should be able to get to grips with OOP etc etc. This will help you in PHP and in any other language you learn in the future.

Now I say go learn C# but that's just because I prefer it. If you don't like the look of it, go learn C++ and vice versa.

Good luck.
Was This Post Helpful? 0
  • +
  • -

#4 tlhIn`toq  Icon User is offline

  • Please show what you have already tried when asking a question.
  • member icon

Reputation: 5529
  • View blog
  • Posts: 11,843
  • Joined: 02-June 10

Re: C# or C++ ?

Posted 13 March 2012 - 02:04 PM

Oh boy - this question again.

See FAQ # 29. (Click the SHOW button below)


TOP most asked:
What does this error message mean?
FAQ 2: How do I debug
FAQ 3: How do I make Form1 talk to Form2


FAQ (Frequently Asked Questions - Updated Feb 2012
Spoiler



Was This Post Helpful? 0
  • +
  • -

#5 Yeronox  Icon User is offline

  • D.I.C Head

Reputation: 2
  • View blog
  • Posts: 102
  • Joined: 12-March 12

Re: C# or C++ ?

Posted 13 March 2012 - 03:26 PM

Thanks for your replies, I read everything and I think I'll choose C#
Hope to start coding something nice soon :)
Thanks!
Was This Post Helpful? 0
  • +
  • -

#6 Choscura  Icon User is offline

  • D.I.C Lover


Reputation: 465
  • View blog
  • Posts: 2,227
  • Joined: 18-October 08

Re: C# or C++ ?

Posted 14 March 2012 - 10:47 AM

As a rule of thumb, C# is a prototyping language-it's fast, memory managed- you don't have to learn to manually create and delete individual blocks of memory in your computer's RAM or HDD, in other words- and it has a lot of nifty stuff built in or easily available that lets you go fast from the start.

C++, on the other hand, is a language that requires dedication, a lot of deep thought about things that you probably couldn't tell apart as a beginner, and a complete re-wiring of your brain. All programming makes your brain work, don't get me wrong, but C++ goes beyond that and demands that you achieve Nirvana before you become a code master. Which is good, because a lot of people did that, and so there are a lot of gurus who can help you along (and they all gather together and whisper about the gurus who, long ago, learned languages even baser and more brain-twisting than C++).

Think of it like a zoo- both languages have the same animals and (technically) the same dangers, but C# starts you in the parking lot by the gate, and C++ starts you on the other side of bars of a random animal's cage every time you start a project. Great if you need horsepower and find zebras, bad if you want koalas and find cobras.
Was This Post Helpful? 0
  • +
  • -

#7 RudiVisser  Icon User is offline

  • .. does not guess solutions
  • member icon

Reputation: 1003
  • View blog
  • Posts: 3,562
  • Joined: 05-June 09

Re: C# or C++ ?

Posted 14 March 2012 - 02:31 PM

View PostChoscura, on 14 March 2012 - 05:47 PM, said:

As a rule of thumb, C# is a prototyping language-it's fast, memory managed- you don't have to learn to manually create and delete individual blocks of memory in your computer's RAM or HDD, in other words- and it has a lot of nifty stuff built in or easily available that lets you go fast from the start.

C++, on the other hand, is a language that requires dedication, a lot of deep thought about things that you probably couldn't tell apart as a beginner, and a complete re-wiring of your brain. All programming makes your brain work, don't get me wrong, but C++ goes beyond that and demands that you achieve Nirvana before you become a code master. Which is good, because a lot of people did that, and so there are a lot of gurus who can help you along (and they all gather together and whisper about the gurus who, long ago, learned languages even baser and more brain-twisting than C++).

Think of it like a zoo- both languages have the same animals and (technically) the same dangers, but C# starts you in the parking lot by the gate, and C++ starts you on the other side of bars of a random animal's cage every time you start a project. Great if you need horsepower and find zebras, bad if you want koalas and find cobras.

Having used and being very proficient in both, I have disagree slightly in that C# is not a prototyping language and can be just as powerful as C++ if the need arises. Of course the learning curves are different, but one over another? They're probably the same (hear me out!). With C# you have to learn the whole .NET Framework to be proficient in it, of course that's not the language itself, but it's 99.999% certain that is how you're going to use it. C++ as a language is slightly more complex in that you have to know more stuff about the inner workings of a computer, but personally I don't class someone as a programmer of any language if they don't know that anyway.

Memory managed language or not, as a programmer, you should have a deep understanding of how computers work; and that is a distinction that many people fail to make. You still have to manage your own memory in C#, albeit in a less direct way.

This post has been edited by RudiVisser: 14 March 2012 - 02:40 PM

Was This Post Helpful? 0
  • +
  • -

#8 Yeronox  Icon User is offline

  • D.I.C Head

Reputation: 2
  • View blog
  • Posts: 102
  • Joined: 12-March 12

Re: C# or C++ ?

Posted 15 March 2012 - 07:02 AM

Started today with C# :)
Thanks for all replies!!
Was This Post Helpful? 0
  • +
  • -

#9 jon.kiparsky  Icon User is online

  • Pancakes!
  • member icon


Reputation: 7760
  • View blog
  • Posts: 13,125
  • Joined: 19-March 11

Re: C# or C++ ?

Posted 17 March 2012 - 05:05 PM

Question - if the point is to learn PHP, why not just learn PHP? It's a completely different animal, although it shares some superficial similarities (ie, algol-ish syntax). To do anything useful in PHP, you'll want to know HTML/CSS, some flavor of SQL, probably javascript or coffeescript or something of that nature...
Sounds like plenty to work on there. If you want to do web programming, C# seems like a weird detour.
Was This Post Helpful? 0
  • +
  • -

#10 lordofduct  Icon User is offline

  • I'm a cheeseburger
  • member icon


Reputation: 2533
  • View blog
  • Posts: 4,633
  • Joined: 24-September 10

Re: C# or C++ ?

Posted 18 March 2012 - 07:10 AM

They said, "C++/C# and PHP".

They're just starting with the C++ and C# first.
Was This Post Helpful? 0
  • +
  • -

#11 turboscrew  Icon User is offline

  • D.I.C Addict

Reputation: 100
  • View blog
  • Posts: 615
  • Joined: 03-April 12

Re: C# or C++ ?

Posted 05 April 2012 - 03:41 AM

The drawback in C# is that it's Windows-only.
Was This Post Helpful? 0
  • +
  • -

#12 lordofduct  Icon User is offline

  • I'm a cheeseburger
  • member icon


Reputation: 2533
  • View blog
  • Posts: 4,633
  • Joined: 24-September 10

Re: C# or C++ ?

Posted 05 April 2012 - 07:07 AM

false - mono brings C# to most modern operating systems.
Was This Post Helpful? 0
  • +
  • -

#13 tlhIn`toq  Icon User is offline

  • Please show what you have already tried when asking a question.
  • member icon

Reputation: 5529
  • View blog
  • Posts: 11,843
  • Joined: 02-June 10

Re: C# or C++ ?

Posted 05 April 2012 - 07:08 AM

View Postturboscrew, on 05 April 2012 - 04:41 AM, said:

The drawback in C# is that it's Windows-only.


Depends on the need. It is the language of Xbox. So if the OP/developer plans to go that route. It actually rather remarkable how much non-gaming you can do on one of those. I've seen a few instances where they were used for single-app purposes that had nothing to do with gaming. Lots of "computer" needs don't really call for the power of a full on computer.
Was This Post Helpful? 0
  • +
  • -

#14 tlhIn`toq  Icon User is offline

  • Please show what you have already tried when asking a question.
  • member icon

Reputation: 5529
  • View blog
  • Posts: 11,843
  • Joined: 02-June 10

Re: C# or C++ ?

Posted 05 April 2012 - 07:19 AM

View PostChoscura, on 14 March 2012 - 11:47 AM, said:

As a rule of thumb, C# is a prototyping language-it's fast, memory managed- you don't have to learn to manually create and delete individual blocks of memory in your computer's RAM or HDD, in other words- and it has a lot of nifty stuff built in or easily available that lets you go fast from the start.

C++, on the other hand, is a language that requires dedication, a lot of deep thought about things that you probably couldn't tell apart as a beginner, and a complete re-wiring of your brain.


This reminds me of old-school photographers that refuse to accept digital and continue to insist that film is the only true photographic medium. Or audiophiles that insist that vinyl is 'richer'.

Just because a managed language like C# makes it easier and faster to write a finished application doesn't make it bad. I'm sure it upsets many people that coders without years of experience can now right a program that isn't riddled with memory leaks. They didn't have to put forth their time in the trenches. Get over it. Its no different than today's internet enabled populous that didn't have to learn BBS systems on 300 baud acoustic-coupled phone modems. Technology moves forward making the one difficult now easy: Then provides a new target of 'difficult'. I sure wouldn't prefer to write a multi-processor, multi-tasking application without the modern IDE tools available.

With the demands the public makes on the software industry today we need all the tools we can get, and that includes languages like C#. The minimum baseline expectations of software rises every year yet the cost expectations and time allotments diminish every year. So yea, give me my fancy-pants IDE and managed languages (that do still let me do unmanaged things when I need to)
Was This Post Helpful? 0
  • +
  • -

#15 turboscrew  Icon User is offline

  • D.I.C Addict

Reputation: 100
  • View blog
  • Posts: 615
  • Joined: 03-April 12

Re: C# or C++ ?

Posted 05 April 2012 - 07:53 AM

Quote

Or audiophiles that insist that vinyl is 'richer'.

Actually it is.
You can hear it if you listen to "TIM-prone" music.
(Lots of enharmonic high pitches) ;-)
Was This Post Helpful? 0
  • +
  • -

  • (2 Pages)
  • +
  • 1
  • 2