Live data from Hacker News

Ask HN: Differences in Programming Style by Nationalities

news.ycombinator.com

1–10 of 38 posts

Ask HN: Differences in Programming Style by Nationalities

#1
In mathematics some people say that there are three different styles of doing mathematics: the French style, the Russian style, and the American style. Each one has its own peculiarities and stereotypes. For instance, French-style mathematics tends to be very abstract compared with Russian-style. Of course, these are all generalizations.

Does something like this exist in the programming world? Example: programmers trained in X tend to be more Y compared to those trained in Z.

Re: Ask HN: Differences in Programming Style by Nationalities

#2
not sure about specifics in training but I had quite a lot of fun reading regular c++ code with variables in english only to scroll and find pages of comments in foreign language like russian or japanese...

another fun with languages happens when coders for whatever reason insist on naming their variables using fusion of english and other language, such as "HornyWidget" (horny means upper in my language)

Re: Ask HN: Differences in Programming Style by Nationalities

#3

not sure about specifics in training but I had quite a lot of fun reading regular c++ code with variables in english only to scroll and find pages of comments in foreign language like russian or japanese... another fun with languages happens when coders for whatever reason insist on naming their variables using fusion of english and other language, such as "HornyWidget" (horny means upper in my language)

MPlayer is originally a Hungarian project and IIRC the code suffered a bit from comments being written in Hungarian, which no one but Hungarians understand.

But that was around 2002 or so. IDK if it is so today. Probably not.

Re: Ask HN: Differences in Programming Style by Nationalities

#4

not sure about specifics in training but I had quite a lot of fun reading regular c++ code with variables in english only to scroll and find pages of comments in foreign language like russian or japanese... another fun with languages happens when coders for whatever reason insist on naming their variables using fusion of english and other language, such as "HornyWidget" (horny means upper in my language)

MPlayer is originally a Hungarian project and IIRC the code suffered a bit from comments being written in Hungarian, which no one but Hungarians understand. But that was around 2002 or so. IDK if it is so today. Probably not.

even their main website was full of hungarian IIRC which was difficult for me :)

Re: Ask HN: Differences in Programming Style by Nationalities

#5
I did witness a Japanese style in the 1990's - a book of coding blocks was being used with the primary value the coder was adding was glueing then together.

Back then, I thought it was idiotic; how could a professional sit there and copy from others.

I now view it as genius - save your effort for the hard problems.

Re: Ask HN: Differences in Programming Style by Nationalities

#6
Programming style could mean different things: architecture, design patterns, spelling, naming, favorite languages, favorite domains, coding styles (tab vs spaces, where to put braces, space or no space before functions).

What probably matters a lot is how programming was learned (self taught, at school, availability of resources from the country / in the language of the person…) as well as the variety of code which the person read / contributed to.

No, that does not answer the question at all because I have no idea :-)

With respect to naming, English being a Germanic language rooting a good part of its vocabulary to the French language, it would be interesting to compare German code and French code both written in English and find out whether German (resp. French) people tend to use more words rooted from the German (resp. French) language.

Re: Ask HN: Differences in Programming Style by Nationalities

#7

not sure about specifics in training but I had quite a lot of fun reading regular c++ code with variables in english only to scroll and find pages of comments in foreign language like russian or japanese... another fun with languages happens when coders for whatever reason insist on naming their variables using fusion of english and other language, such as "HornyWidget" (horny means upper in my language)

I interviewed at a Dutch company that had offices in Paris and the French programmers insisted in using French for all identifiers. Effectively it was job security for them.

Re: Ask HN: Differences in Programming Style by Nationalities

#10
I first noticed a difference in national styles when I contributed a patch to fastjson, a JSON parser in Java from Alibaba.

Take a look around the repo; it'll look odd to a western programmer. There is a lot of duplication. And the tests don't have names, they are numbered.

https://github.com/alibaba/fastjson/blob/master/src/test/jav...

This was several years ago. I did end up choosing it since it really was the fastest.

Post reply on HN