To me, the scariest thing a programmer can say is, "I don't like X, I'd rather use Y," where X and Y are the names of programming languages. It means that whoever said this has fallen into the language trap.

We, as computer scientists, have many different programming languages at our disposal. From object-oriented languages like Java and C# to functional languages like LISP and Haskell to interpreted languages like BASIC and Perl to entirely bizarre languages like those found on Esolang, the esoteric programming languages wiki. Those of you not familiar with this might tend to think, "Why do you have so many different languages? Isn't programming just telling the computer to do things?"

The reason why we have so many different languages is because each language is created with a particular set of problems in mind. Though each language is inevitably compiled or interpreted into the same machine code, different languages are more suited to specific tasks than others. In general, if a language was designed for a specific task in mind, then if you are writing software that needs to accomplish that specific task, then you should be using that language.

For example, Perl was designed for parsing strings; Java is designed primarily for platform independence (the same code can be run on any machine running any operating system); XSL was created specifically to parse XML documents and transform them into other document types in entirely different (if desired) formats. I can go on. There simply too many programming languages to enumerate here.

It is paramount as a programmer to know as many different languages as possible, if only at a high level. Obviously no one person can have intimate knowledge of all languages; however, one can easily know the major language paradigms and know major languages that implement those paradigms. Indeed, even across language paradigms the majority of programming concepts still hold firm. After all, all languages are there to accomplish the same goal: to facilitate the programmer in creating the desired software. The differences are just niceties that allow us to produce software faster and better.

And thus is the language trap. One is trapped if one thinks one language or paradigm is fundamentally better than all others. Someone who is trapped in a language will not see that it is silly to write string-parsing libraries for XSL, or that JavaScript's object-oriented facade is nothing more than buzzword compliance (more on this some other day). This person will spend days trying to mutate one language (his preferred language) into an already-existing language he doesn't know about because his mind is closed to alternatives.

The language trap can even instill such arrogance in those trapped that they speak such nonsense as denying an entire paradigm as useless simply because it does not conform to their ideals. Take a look at this article, Inheritance is evil, and must be destroyed. Inheritance is a fundamental concept in object-oriented programming. Due to his exposure to JavaScript's terrible object-oriented implementation, the author builds a straw man example of how inheritance should not be used in any situation. He is simply missing the whole picture, most likely because his only exposure to object-oriented design is in his preferred language.

I'm not entirely sure how people first fall into the trap. I know of several people from both real life and online who have fallen. In one case, I suppose he fell for rhetoric from those who were already trapped. In other cases, I'm not so sure. I do know that practically no time at all is spent teaching this lesson to university students (at least at Waterloo, my alma mater), beyond teaching a few different paradigms. No extra effort was expended by saying, "No language is suited for everything, and so while it's OK to have a preferred language, it's not OK to not consider using a different one." How much impact such advice would have, I don't know.

One language does not suit every task. If that were so then we'd only have this one magic language and no one would ever have the need to create new languages. Don't fall into the trap — learn as much as you can!