December 12th, 2006

The never-ending cycle of incompetence

Every semester in my intro class, I teach programming. (In C++, if anyone cares).

Learning programming is hard, and has lots of details to confuse people, and requires a certain level of abstract thought that, sadly, not all students have.

On top of that, every semester the class, seemingly independently, decides to all go insane on one topic concurrently.

Every semester, there's just one crazy-stupid thing that all of the students- even the good ones- do wrong, and can't seem to figure out why they're messing things up. Last semester, people went nuts putting type names in function calls. It was the strangest thing, and only when I ranted about it to an upper-level class did I get a semi-plausible explanation.. that most people paste a copy of their function definition (which has type names in it) as their function call (which doesn't need type names), and they forget to remove the type names.

So, this semester, when we did the function chapter, I made this a big deal-in class, on the lab, in emails, "DON'T CALL FUNCTIONS WITH TYPE NAMES!"

And it mostly worked. But rather than making this make their programs work, they find new and interesting ways to screw things up. This semester's culprit is the randomly placed semicolon. And to be fair, a very common error from the compiler is "error- semicolon expected". But a good portion of the time, that doesn't actually mean you need a semicolon. It means "dude, something just went crazy, so I'm going to assume your last line didn't end correctly". If you put in a semicolon just to shut up the error, you'll get errors (and usually harder to find errors) down the road.

So, I've traded one type of strange error for another. And when I teach this class again, if I beat the semicolon thing into them, something else will pop up.

It's frustrating, but I think it's a fact that if you're learning this stuff, you can only hold so many things in your head at once..