# C# as a starting point?

## Recommended Posts

Hi everybody, I’m kinda new to this community. I really wanna learn a game programming language and was attracted by C#. The reason is that seems at the same time powerful, easy to learn and quite “innovative”. I would like to understand from you guys if this would be a nice choice to start or if is necessary to first focus onC/ C++.. I’ve also notice that you have great tutorials for both, so I’m quite excited about that and eager to start.. Thanks for your help, Encio

##### Share on other sites
Given the choice between C++ and C# I would always recommend C# to a beginner. It will be easier to learn and more productive to use. If you later want you can still learn C++, which will be far easier to do if you already know C#, since their syntax is pretty similar.

Quote:
 I would like to understand from you guys if this would be a nice choice to start or if is necessary to first focus onC/ C++..

There is no almighty, god given rule commanding you to programm in C++ (At least none that I know of^^) You will be fine with any language you choose and feel comfortable with.

##### Share on other sites
wow thanks, that's just the answer i hoped to recive :=)

##### Share on other sites
Quote:
 Original post by Enciowow thanks, that's just the answer i hoped to recive :=)

In contrast with the first reply, I would never recommend C# as a first programming language unless you have plans to become a business application or web developer. Please take a look at this article:
http://www.stsc.hill.af.mil/CrossTalk/2008/01/0801DewarSchonberg.html
Read section "The Pitfalls of Java as a First Programming Language". This is about Java, but also applies to C# very well.

##### Share on other sites
Again, I've always heard that it's best to start from the top and work your way down. Therefor, starting with the more difficult language, and then once you are comfortable with that, work on simplifying your process by dabbing in the easier ones.

##### Share on other sites
Quote:
 Original post by sto8qcIn contrast with the first reply, I would never recommend C# as a first programming language unless you have plans to become a business application or web developer. Please take a look at this article:http://www.stsc.hill.af.mil/CrossTalk/2008/01/0801DewarSchonberg.htmlRead section "The Pitfalls of Java as a First Programming Language". This is about Java, but also applies to C# very well.

Well, I disagree.

Quote:
 Students found it hard to write programs that did not have a graphic interface, had no feeling for the relationship between the source program and what the hardware would actually do...

This is true for most people who just started programming, no matter whether they started with java, c# or c++

Quote:
 ...and (most damaging) did not understand the semantics of pointers at all, which made the use of C in systems programming very challenging.

In C# you can use pointers as much as you please (in unsave code), also if you are learning C# you sooner or later will have to learn the difference between value und reference types and about boxing/unboxing, which will give you a (at least basic) understanding of pointers.

Quote:
 The irresistible beauty of programming consists in the reduction of complex formal processes to a very small set of primitive operations. Java, instead of exposing this beauty, encourages the programmer to approach problem-solving like a plumber in a hardware store: by rummaging through a multitude of drawers (i.e. packages) we will end up finding some gadget (i.e. class) that does roughly what we want. How it does it is not interesting!

I can't see this apply to C#. The FCL does provide a hole bunch of usefull classes, that make your life easier, but this is a clear advantaqe for a beginner. Most C++ beginners will take a similar approach and download libraries to make their life easier, or even worse copy and paste code from the internet or a book.

Starting with C# will be easier and learning won't stop after that. You can later always go to C++ or even assembler if you want.

[Edited by - DraganO on March 16, 2009 9:51:32 AM]

##### Share on other sites
Pick a language - any common/popular language - and get to work learning. The important thing is to get started with something and then sticking with it until you get results. The underlying concepts will transfer from one language to another, and you'll find that once you've learned your first language it'll be significantly less difficult to pick up other languages (excepting perhaps particularly different or esoteric languages) if you need or wish to do so.

Personally I'd recommend C# to a beginner over C or C++, although any of the three will work if you stick with it. Like DraganO, I commonly recommend C# to beginning programmers.

##### Share on other sites
Quote:
 Original post by sto8qcIn contrast with the first reply, I would never recommend C# as a first programming language unless you have plans to become a business application or web developer.

In support of the first reply, I always recommend C# as a first programming language these days.

Quote:
 Please take a look at this article:http://www.stsc.hill.af.mil/CrossTalk/2008/01/0801DewarSchonberg.htmlRead section "The Pitfalls of Java as a First Programming Language". This is about Java, but also applies to C# very well.

Sure, an insightful article that cautions against learning to 'make stuff in $X' and instead to learn computer science. As DraganO alludes to, this also applies to any language. That you recommend C# to business/web devs makes me inclined to think that the point of your link has eluded you. #### Share this post ##### Link to post ##### Share on other sites I would like to ask those guys who advocates C# as a first language a question - What do you think is the ratio of developers who started with C# and can program in C++ between developers who started with C++ and can write in C#? Do you think that it is 1:1? I see people there and here who tell that "do the easy thing first, the you can do some hard stuff". It is simply not true. People cannot easily change their way of thinking after they learn something. Once they learn to think in high level, they will try to apply that in whatever they do. Quote:  Sure, an insightful article that cautions against learning to 'make stuff in$X' and instead to learn computer science. As DraganO alludes to, this also applies to any language. That you recommend C# to business/web devs makes me inclined to think that the point of your link has eluded you.

I'm impressed how you associate unrelated sentences.
I think that C# is good for business software. Guy who wrote tha article thinks that Java is popular in web industry. How does my opinion of one language is related to possible reason of popularity of other language?

##### Share on other sites
Quote:
 Original post by sto8qcI would like to ask those guys who advocates C# as a first language a question - What do you think is the ratio of developers who started with C# and can program in C++ between developers who started with C++ and can write in C#? Do you think that it is 1:1?

Of course not, c++ has been around for much longer than c#. But the principles of programming are language independent. It doesn't really matter what exactly your first language was.

Quote:
 Original post by sto8qcPeople cannot easily change their way of thinking after they learn something. Once they learn to think in high level, they will try to apply that in whatever they do.

I don't think so. As soon as you begin to become better at programming in your first language (whatever languages this may be), you will want to learn other languages and want to understand what you are doing on a lower level. Which will effectively make you a better high-level programmer.
Are you suggesting all beginners should grab an hexeditor and start hacking machine code, just for the sake of being low-level? After all C++ is still pretty high-level.

##### Share on other sites
C# is not a bad first language, certainly better than C++, but I would recommend Python over it any day. Firstly C# requires you to put everything in classes which, apart from being a pet peeve of mine, doesn't make sense with beginners programs like hello world, guess the number, hangman and such. Secondly the dynamic typing of Python makes it great for beginners. They don't have to worry about declaring their variables ahead of time and such. I prefer static typing for large projects, but the dynamic nature of Python is great for learning. Thirdly the REPL is great for experimentation.

C# is a good language, and if you have chosen it to start with, don't let this change your mind. Just when people ask me where to start, I always answer Python.

##### Share on other sites
Quote:
 Original post by sto8qcI would like to ask those guys who advocates C# as a first language a question - What do you think is the ratio of developers who started with C# and can program in C++ between developers who started with C++ and can write in C#? Do you think that it is 1:1?

I don't care.

I am more interested in the ratio of beginners that become good programmers.

Quote:
 Once they learn to think in high level, they will try to apply that in whatever they do.

Good.

Quote:
 I'm impressed how you associate unrelated sentences.I think that C# is good for business software. Guy who wrote tha article thinks that Java is popular in web industry. How does my opinion of one language is related to possible reason of popularity of other language?

Sigh.

The entire point of the article is 'Computer Science is good'. The authors lament the movement of programs away from mathematical based computer science to a less formal one. That such a change coincides with the introduction of Java to university courses is not really significant.

Saying that what language you start with depends on what you want to do 4+ years down the road is (in my opinion) not really using the right priorities.

Quote:
 Do you think that it is 1:1?

I think that if they follow your link's advice and learn computer science, it'll be significantly closer to 1:1 than if they don't; regardless of language.

##### Share on other sites
sto8qc, your points are unrelated, wrong, and/or irrelevant, and you appear to have misunderstood the point of the very article you tried to link in support of your own half-baked argument. Please refrain from posting that kind of misdirection and misinformation in this forum. You may consider this your warning.

##### Share on other sites
Quote:
 Hi everybody,I’m kinda new to this community.

Welcome.

Quote:
 I really wanna learn a game programming language and was attracted by C#. The reason is that seems at the same time powerful, easy to learn and quite “innovative”.I would like to understand from you guys if this would be a nice choice to start or if is necessary to first focus on C/ C++..

The first two points are valid, although there is in actuality little about C# that is innovative in contrast with other (although perhaps less-well-known) programming languages. A lot of new, innovative language features are developing in research / academic / "toy" languages and then later get folded into languages that have a more mainstream target market. But that doesn't invalidate C#'s value as a first language. It would be an excellent place to start learning programming.

Quote:
 I’ve also notice that you have great tutorials for both, so I’m quite excited about that and eager to start..

There was a C# workshop that was hosted here by moderator JWalsh a while back. You can dig up the threads in the forum list, I think they're near the bottom. While the workshop itself is over, there's an introductory thread that lists a bunch of good C# learning resources.

##### Share on other sites
Yes I was referring to the workshop. I know is over, i wanted to partecipate when it was launched but had some external life issue that prevent me for doing so.

In relation to my "innovative" in my first sentence, you're right. I just wanted to say that the language is "new" instead of "innovative" :P

some limits in my english, sorry :)

thanks a lot everybody for your opinions and suppot

##### Share on other sites
Quote:
 Original post by jpetriesto8qc, your points are unrelated, wrong, and/or irrelevant, and you appear to have misunderstood the point of the very article you tried to link in support of your own half-baked argument. Please refrain from posting that kind of misdirection and misinformation in this forum. You may consider this your warning.

Wow. I don't care for language arguments, so I never enter these threads, but I feel compelled to comment on this. Someone asked a question, sto8qc gave an opinion that was related to the question, and provided a relevant article. His post was on topic and non-offensive. If you think his opinion is wrong, then give some arguments as to why - that's the whole point of a forum. If you think the thread has devolved into deconstructive debate (language war, etc), then sure, remind people of that or close the thread.

What you've done is essentially exercised your police powers as a moderator to tell someone to STFU. That's precisely what a moderator is supposed to prevent from happening. GD.net works because there are people of many different skill levels and with many different opinions all offering advice and discussing things with each other. If people are afraid of posting because they think some expert (or jerk) is going to reply and tell them to shut up and they're wrong, then we all lose.

##### Share on other sites
Quote:
Original post by jdindia
Quote:
 Original post by jpetriesto8qc, your points are unrelated, wrong, and/or irrelevant, and you appear to have misunderstood the point of the very article you tried to link in support of your own half-baked argument. Please refrain from posting that kind of misdirection and misinformation in this forum. You may consider this your warning.

Wow. I don't care for language arguments, so I never enter these threads, but I feel compelled to comment on this. Someone asked a question, sto8qc gave an opinion that was related to the question, and provided a relevant article. His post was on topic and non-offensive. If you think his opinion is wrong, then give some arguments as to why - that's the whole point of a forum. If you think the thread has devolved into deconstructive debate (language war, etc), then sure, remind people of that or close the thread.

What you've done is essentially exercised your police powers as a moderator to tell someone to STFU. That's precisely what a moderator is supposed to prevent from happening. GD.net works because there are people of many different skill levels and with many different opinions all offering advice and discussing things with each other. If people are afraid of posting because they think some expert (or jerk) is going to reply and tell them to shut up and they're wrong, then we all lose.

While that is generally true on GDNet, this is the For Beginners forum, and as such special rules apply to help keep impressionable beginners from getting the wrong information and running with it. If he wants to discuss the merits of his opinions, he will have to abide by the moderator's mandate and move it to a different forum.

##### Share on other sites
I've always been told (by my parents/close relatives) that it's always best to learn the difficult first: and then move down to the more applicated things..

First learn physics and then applied engineering!

For that "line" (which I'm studying at the university) it works exceptionally well: it gave me a good headstart, and I've become never afraid from difficult problems! - Also it allows me to see the larger picture, and I'm easier in seeing connections/similarities between problems!

This is also what I'm doing for programming: first I learn how memory is laid down in the computer, and then move my way "down" (or "up" would be a better wording in this case) the ladder to more application-minded languages.

So I started with learning C/C++ (and especially looked for tutorials that explained also the internal workings directly at the start).

I'm not able to give a "review" from this yet: I haven't learned much (lack of spare time is probably the main reason :( ). But I still believe in the end it will make me a more complete programmer!

##### Share on other sites
Quote:
 Original post by paul23first I learn how memory is laid down in the computer, and then move my way "down" (or "up" would be a better wording in this case) the ladder to more application-minded languages.So I started with learning C/C++ (and especially looked for tutorials that explained also the internal workings directly at the start).

No offense meant, but if you think that C and C++ provide an accurate representation of how memory is "laid down" in a computer, then your education method is seriously flawed. After all, C beginners often get the impression that memory is linear and truly random-access, as this seems to be how pointers are. At least C# beginners won't be misled, even if they won't get this "understanding."

##### Share on other sites
From experience, I recommend C++, even for beginners. Thats the I started.
It might be hard at first, but sooner or later it will click, and you will realize that there was nothing hard to understand this language.

##### Share on other sites
Quote:
 Original post by tnuttyFrom experience, I recommend C++, even for beginners. Thats the I started. It might be hard at first, but sooner or later it will click, and you will realize that there was nothing hard to understand this language.

Oh? take these 3 Quizzes from Washu and let us know how well you actually know this easy language. One. Two. Three.

##### Share on other sites
I just wanted to voice my opinion in this matter.

My first language I learned was Java by taking a class in high school (teacher was a complete idiot and didn't actually teach but that's beside the point). So I learned it by myself from a book. From there I took a c/c++ class at my local community college. I got the highest score out of the whole class. Since then I've moved onto a real college studying Embedded systems. I am just finishing up my first assembly class (once again highest grade in the class) and have had no trouble understanding it (but I did ask a whole ton of questions during the class).

I'm telling you all this because I don't believe Java being my first language has hurt me in anyway, if anything it made the transition to tougher/lower level topics like pointers and memory management easy to learn.

I do believe it is tough to truly appreciate the power and simplicity of higher level languages with learning what's going on behind the scenes. But that can be learned later (as I have and I do truly appreciate how great higher level languages are, and how the simplify/speed up development).

just my 2 cents, I wanted the OP to get an opinion from someone who started out with a high level language and that it hasn't hindered me in any way.

##### Share on other sites
I'd definitely wouldn't recommend C/C++ to a beginner. In my opinion C++ syntax is just unnecessarily complicated for a beginner. C will not teach you OOP (object oriented programming). OOP is omnipresent in modern software development and not picking it up right when you start programming may just make it so much harder to "get it" later. I know a ton of older programmers (20+ years of industry exp.) who still didn't really embrace OOP (they stick to their "good old" ways) and it is causing serious problems in their careers.
C# is definitely a good choice - besides all the other comments I'd like to add that C# is evolving very rapidly and it is incorporating some features from dynamic and functional programming languages. This will allow you to learn a little bit about the other programming paradigms thus hopefully making you a better programmer...

##### Share on other sites
Quote:
 Original post by jpetriesto8qc, your points are unrelated, wrong, and/or irrelevant, and you appear to have misunderstood the point of the very article you tried to link in support of your own half-baked argument. Please refrain from posting that kind of misdirection and misinformation in this forum. You may consider this your warning.There is to be no further discussion of this little tangent in this thread. Please return to the OP's original question.

Sorry, I do not understand why I am wrong in your opinion. Please explain.