Linked by MOS6510 on Wed 17th Apr 2013 21:20 UTC
General Development "You often hear about how important it is to write 'readable code'. Developers have pretty strong opinions about what makes code more readable. The more senior the developer, the stronger the opinion. But, have you ever stopped to think about what really makes code readable?"
Thread beginning with comment 558974
To view parent comment, click here.
To read all comments associated with this story, please click here.
RE: Vocabulary
by WorknMan on Thu 18th Apr 2013 01:35 UTC in reply to "Vocabulary"
Member since:

So, his point is that a big vocabulary lets a writer feel good about what he is writing -- he feels he is saying exactly what he wants -- but his subtilty is lost on beginners.

There is this thing that happens -- an author can get mesmerized by his craft. He gets great satisfaction when he picks the right word, like he's playing sudoku. This is a vainity.

Yeah, reminds me of reading some Perl code. It seems that a lot of Perl programmers will go out of their way to write code in the least amount of lines as possible, and to hell if anyone but Perl gurus can actually read it. And the end result looks like modem line noise on a terminal. It's like prog rock bands who will play solos for 40 minutes, if for no other reason than to show off, thereby alienating everyone in the audience, except for the 1% who are also prog rock snobs. Note that I'm not dissing either Perl or prog rock, because I like both ;) Just bitching about the excesses of both.

In his article, he says whether or not you should put code on one line or stretch it out to a few depends on who your audience is. I say that's horseshit. If there's two ways to write the code, you should always put it in the form that's easiest to read, especially since you never know who's going to be debugging your code 10 years from now. At least that way, even if experts are a bit irritated by the simplicity of it, you know everyone is going to be able to read it.

Edited 2013-04-18 01:36 UTC

Reply Parent Score: 4

RE[2]: Vocabulary
by Lennie on Fri 19th Apr 2013 10:55 in reply to "RE: Vocabulary"
Lennie Member since:

One day when Larry Wall was writing Perl code his dauther had a look at the screen and asked him: is this swearing, daddy ?


Reply Parent Score: 2