Hey programmer, why don’t you code in english?

It is hard to believe, at least for me, that there are still programmers out there who code in their native, non-english, language, i.e. they use non-english names for classes, methods, variables, etc. Of course, it is easier to use your native language than a foreign language. You think in your native language, and know all the words you may need without consulting a dictionary. Even though it is a bad practice to use an other language than English to write your code. Why? Let me explain.

  • English is the defacto standard language for code. Almost all programming languages, frameworks and libraries use English for their APIs
  • Code written in one language is easier to read than code that mixes two languages (I think you wouldn’t like it if I would mix german and english words in my posts *g*)
  • Code written in a non-english language excludes a lot of programmers from understanding your code, with the following consequences:
    • It is more difficult to get help in newsgroups, forums, etc.
    • It is more difficult to outsource the development of parts of your application
    • Your framework or library won’t be used

You see, there are more disadvantages than advantages when using a non-english language for your code. So there is no reason to stick to your non-english language anymore (except for maintenance purposes).

11 Comments

  1. Hubi
    Posted July 16, 2006 at 8:30 pm | Permalink

    I can’t agree 100%. Sometimes needs to use native languages in the code. Just think of SEO problems. If I provide content in my native language, I have to use native words in my urls, otherwise I’ll get worse hit ratio.
    If we see someone’s own propriatery project, I think the used language in the code is totally unimportant. In the case of shared code the situation is certainly totally different, the common communication language is the english.

  2. Posted July 17, 2006 at 1:13 am | Permalink

    Half of the time, supposedly-English-speaking programmers use nonsensical variable names, so who cares if they’re sensical in another language. It may even help someone if they now that language. Not all programmers are monoglots and English-enforcement isn’t healthy.

  3. Posted July 17, 2006 at 1:13 am | Permalink

    s/they now/they know/; Damnit, how can you proof-read anything in an input box this small?

  4. Posted July 17, 2006 at 8:59 am | Permalink

    Well, what if they don’t care about the English speaking population?

  5. Posted July 17, 2006 at 9:45 am | Permalink

    @Hubi: I don’t have experience with SEO, but to me it seems like an additional layer on top of your application. In cake that means I would probably use routes.

    Yes, for private projects the used language is not that important. But even in such a project I would recommend to use english, as in case you need help it is easier to get help in english (compare the number of subscribers of the english and german google groups).

    @MJR/slef: Yes, it happens that nonsensical variable names are used, but that happens even if you use your native language ;-)

    Whether English-enforcement is healthy or not, I don’t know. For me it is just a fact I have to live with.

    @tariquesani: I am not sure to which point you are refering. Can you make it more clear?

  6. Posted July 17, 2006 at 12:14 pm | Permalink

    hey daniel,

    I agree that most (if not all) coding should be done in english. When I started ThinkingPHP I thought about making some German posts from time to time as well, but I realized that the audience would be way to low to do that. Same goes for code. While I try to help spanish/french/whatever people in irc/group if I have time, it’s more difficult to understand what they are trying to accomblish if variables, classes, comments, etc. are done in their native languages. So I’m much more motivated to respond to english (code) support requests, then to ones in other languages.

    However, if you work with a local group and you only depend on your own libraries/framework or ones done by people who speak the same language as you, it would maybe be more efficient to break with english as the standard language. But unless you have everything planned out very carefuly (which I seldom do ^^), you might find yourself working with a english library, making your code become difficult and weird to read.

    Nice post and it’s been interesting to see the different oppinions on this topic ; )

  7. Posted July 17, 2006 at 1:12 pm | Permalink

    @cakebaker: re tariquesani: I guess he/she is trying to point out that if your target programmer audience isn’t English-speaking, then none of the claimed advantages are advantages. Some could even be disadvantages. Many of the code keywords in languages we use don’t have the most common English meaning anyway.

    By the way, I’m quite happy for you to post in German sometimes if it allows a more accurate rendition of your message. It’s a bug to assume English monoglot is best for every audience, before you do the research.

    Code without translated documentation has many problems being maintained or used anyway, whether the source documentation is English or some other language. Also, I’ve seen API docs written by English-as-a-second-language(2L)-speakers where they’ve misphrased something and it’s ended up just plain wrong. With a few exceptions, documentation is a translation from code to prose and is best written by 1L-speakers in their first language, like other translations. That’s not always possible, I know.

    Finally, even many English-1L-speaking programmers don’t use English properly, having grown up in places like the USA or England since they stopped teaching language and grammar at school. Many German-1L-speakers seem to speak USA English rather than normal English too. What’s a bit more language butchery between friends?

  8. Posted July 18, 2006 at 5:56 am | Permalink

    @cakebaker – MJR explained my point very aptly

  9. Posted July 19, 2006 at 12:42 am | Permalink

    hya.
    i’m using cake to code a quite big web app, to work fine in portuguese. Since it’s like 40 different models, each with many different controller actions, how could it be done in english ?

    using routes would be (almost insane), i think.
    examples:
    /listas/usuario/3
    /filmes/mostrar/o-poderoso-chefao

    it doesn’t make sense *to the user* if it’s all in english.

    lovely blog, btw ;)

  10. erikb blondel
    Posted January 4, 2007 at 3:09 pm | Permalink

    #
    # It is more difficult to outsource the development of parts of your application

    precisely, you [offense removed]
    i do not want to be outsourced !

  11. Posted January 4, 2007 at 3:42 pm | Permalink

    @erikb blondel: Well, outsourcing is a reality, if we like it or not. But outsourcing is not the panacea of software development as it is touted.


One Trackback/Pingback

  1. British Languages

    Is English Enforcement in free software
    programming a growing problem?
    I was surprised to see
    a call for all programs to be English-only [cakebaker]…

%d bloggers like this: