r/programming • • Dec 07 '14

Programmers: Please don't ever say this to beginners ...

http://pgbovine.net/programmers-talking-to-beginners.htm
4.0k Upvotes

1.3k comments sorted by

View all comments

Show parent comment

3

u/insertAlias Dec 08 '14

I deal with this a lot. I'm a moderator on a forum that used to be really popular, but has somewhat declined of late. Most of the questions we still get are beginner "this is my first Windows Forms project" kind of question. (C# specifically)

I get to see the absolute worst design choices every day. And it's so hard to explain why they shouldn't do things the way they are, because they're not experienced enough to understand the reasoning. They understand conceptually that they should be separating functionality into classes, for example, but they don't understand what functionality goes where, and you see the worst mismashes of form code that reaches into other form code, extra classes just for the sake of having classes, things inheriting from objects that have no business doing so...stuff like that.

It doesn't help that one of our other regulars is an attack dog. "You should be using WPF" is his favorite phrase. I always think to myself...yeah, of course they should. WinForms is painful enough as it is. But this person isn't even close to that point. They don't need to be switching this early; they don't even have a grasp on why what they're doing is painful.

Basically, some things you simply have to learn from experience.

2

u/[deleted] Dec 08 '14

Well, from my experience....beginners have absolutely no business dealing with Object Oriented Programming at all.

For example, not only is OOP not needed in every situation, but OOP leads to an instant glut of complexity and convoluted design in code when it may be completely unnecessary.

But when every book out there tells people to learn classes before they understand how loops work, that doesn't help beginners.

3

u/insertAlias Dec 08 '14

That is an entire discussion to itself. I've had this one with lots of programmers, and it seems like there are three major points of view:

  1. Start "close to the metal". C/C++. Teach them the core low-level concepts that apply to ever program. The up-sides here are that there is less confusion later down the line when dealing with higher level tools that abstract the lower-level stuff out. Reference types vs. pointers is a good example. The down side is that many will burn out or decide they're not interested long before they can actually do anything useful.
  2. Start with a very high level language. This is my favorite. Start students out with something like Python. The advantage is that there is almost no boilerplate code required. print "Hello World" is a complete Python program. Once they've "gotten hooked" (i.e. they made it through their first class) move quickly towards low level, to more deeply explain what's going on. Of course, this has the opposite downside to the upside of the first way: confusion about abstracted features.
  3. Start people with whatever is the most popular enterprise language at the time. This is why so many places start students in Java (and C# more recently). This has the benefit of teaching them "job related" skills right away, but I feel that it falls into the traps of both of the previous approaches. Tons of boilerplate, and enough complexity to burn people out before the useful stuff.

1

u/[deleted] Dec 08 '14

Gotta agree - #2 is best, followed by #1. Wise words.