Coders Unite

Reading Jeff Atwoods latest blog entry, inspired me to kick of again [1] with a rant. I usually agree with Jeff’s statements, and this time I too do agree that scripting languages are a positive development in language evolution. They opened up many opportunities and make life a whole lot simpler with respect to mundane aspects of “real programming” like memory management, edit and compile cycles, and so on. But I cannot disagree more with the rest of what he is saying.

To summarize, he basically says that you have “real programmers” and scripters:

I remember that evening only vaguely […] Tonight, I become a real programmer. And so I began.

What happened next was the eight unhappiest hours of my computing life. Between the painfully slow compile cycles and the torturous, unforgiving dance of pointers and memory allocation, I was almost ready to give up programming altogether. C wasn’t for me, certainly. But I couldn’t shake the nagging feeling that there was something altogether wrong with this type of programming. How could C suck all the carefree joy out of my stupid little AmigaBASIC adventures? This language took what I had known as programming and contorted it beyond recognition, into something stark and cruel.

I didn’t know it then, but I sure do now. I hadn’t been programming at all. I had been scripting.

I don’t think my revulsion for C is something I need to apologize for. In fact, I think it’s the other way around. I’ve just been waiting for the rest of the world to catch up to what I always knew.

Yes, scripting languages are certainly different from the conventional compiled languages. But that does not say anything about the person writing the code: scripters are real programmers too. They are, and can be much lazier than “real programmers”. Which is a compliment: programmers should be lazy:

Only a lazy programmer will avoid writing monotonous, repetitive code. The tools and processes inspired by laziness speed up production.

Scripting langauges are such tools. But also for writing great programs in scripting languages you will need to have “real programming” knowledge.

You’ll write shit-script-code if you don’t know about data encapsulation: you won’t make use of powerful things like object oriented features of language like Perl or Python. Not only in C, but in scripting languages too you can introduce deadlocks and race-conditions when you are running your code in multiple threads or processes. You will face the same problems maintaining hundreds of thousands lines of script language code as with the same amounts of “real programming” language code.

I believe it is wrong and harmful to divide coders into two camps: the scripters and the real programmers. Whether you are programming C, C++, Python, PHP, Java, C#, Visual Basic, Javascript, Erlang, ADA, D, x86 Assembly, Tangram, Delphi, or whatever programming language of your choice: we all face the same challenges, so let’s face them together.

Near the end of A Scripter at Heart, Jeff concludes:

Every language has its place, and every programmer should choose the language that best fits their skillset and the task at hand.

I agree partly: every programmer should choose the language that best fits the task at hand. If there are multiple options that are equally well fitted for the task, then choose the one that best fits your skillset. None of these languages in your skillset? Then learn a new one, or pass on the task.

[1]After changing houses; I’m (practically) done moving from Utrecht to ‘s-Hertogenbosch. Yes, I will need to update the background title picture, since that one was taken in Utrecht.