Coding: It's Just Writing

In The Programming Aphorisms of Strunk and White, James Devlin does a typically excellent job of examining something I've been noticing myself over the last five years:

This is a companion discussion topic for the original blog entry at:

Long Live COBOL!

Agree with the post

From what I can tell, I hope some of the posters on this blog are not writing code…

While I agree with the post, something I’ve always wondered about is the relationship of diagrams and code. Often I want to comment my code with a diagram, not a paragraph, but I’ve never found a good way to do this.

I’ve even tried writing code in MS Word (which has a reasonable editor for graphics) and shipping it out to the compiler. It worked surprisingly well.

Perhaps this helps to explain why the quality of the code we receive from offshore colleagues is, on average, very poor? If you do not have a strong grasp of the English language, can you write good code?

Maybe that’s why more things are not open-source, people are just too embarrased of their writing abilities and poor spelling with variable names like yeild or zylaphone.

Sorry but in a similar note, well more in how your writting is presented…

Is it me or Jeff’s blog has the WORST FONT ever?

It kills my eyes, it is difficult to read in my firefox, the letters are too small and close together.

Well that is my personal opinion anyway :slight_smile:

Excellent post! The quote from Knuth just made me fully aware of how I must write code from now on.

And Raymond Chen said, (OK, quoted), Writing specifications is like writing a novel. Writing code is like writing poetry.

Agree that code must be written for humans and computers though I certainly prioritise the former.

But I do disagree that most of us enter this field because the machines are so much more logical than people. In my experience the vast majority of software engineers like solving hard problems.

I think one does not need to have a strong grasp of the English language in order to code well… If one can explain everithing like the american indians or tarzan.

When I zoom in two steps in firefox, the font looks just fine here.

I’e had a copy of Strunk and White on my, physical, desktop for years. To some degree it’s why I’m employed. And I’m 60+.

The comments are interesting. I think that about 20 - 30 % get it. For example

I was a lawyer before becoming a coder. Strunk and White always holds pride-of-place next to the Constitution on my bookshelf. But, I hadn’t thought about how writing may have informed my coding until this article. Definitely food for thought.

By the way, many people don’t seem to realize that E.B. White is the same E.B. White who wrote Charlotte’s Web and Stuart Little. Read Charlotte’s Web (to a child if you’re too embarrassed)if you want to see Strunk and White brought to life.
Eo Raptor on November 10, 2008 10:11 AM

I got an A in my Fortran 4 class. I wrote brute force programs, but as my instructor told me, yea you got it right and it worked, but it wasn’t elegant.

Strunk and Write, a 40 -50 pqge tiny book will teach you elegance.

I did a similar comparison to On Writing Well a while back here:

Is it me or Jeff’s blog has the WORST FONT ever?

99.99% of the time this means you have the C fonts from Office 2007 (or Vista) installed, but you have ClearType disabled. Enable ClearType, or delete the C fonts from your system – they’ll never look good until ClearType is enabled.

Slavishly following their advice will make your writing obscure and pedantic, not clear and communicative.

Isn’t this true of slavishly following any advice? I would hope readers are self-reliant enough to take the things from the book that make sense to them, and leave the rest. Sure, not every rule is that essential, but there’s a core of excellent advice there that I see most neophyte writers struggling with, and mostly failing.

Is anyone else tired of Jeff reviewing a book and including a referral link to Amazon?

I’ve been including referral links on any books I talk about for almost five years – and you’ve just now noticed this?

Is anyone else tired of Jeff reviewing a book and including a referral link to Amazon? I realize he makes money off of this site - but come on. It’s kind of like, I don’t really have anything to talk about, so let me pick a book from Amazon, try to write something about it and relate it to software development and I’ll include a referral link to it.

Complete waste of my time. I swear I’m going to unsubscribe to this blog.

I’m surprised that you would say that Coding is just writing. After all, isn’t your favorite book Code Complete by Steve McConnell? He dedicates an entire chapter to software metaphors, including Software as Writing in Chapter 2.3. There and throughout the book he points out that the Software as Writing metaphor works well on the individual and small projects, but leaves the party early for larger projects, where he instead preferrs the Building Construction metaphor.

It’s not that there is no truth to the Software as Writing metaphor, it’s just that it’s not the best analogy - and it is certainly not one size fits all! I agree with much of this post, I’m just surprised that you didn’t make reference rest of the Big Picture.

I could not agree more.

My own preference is for The Complete Plain Words (, which I believe should be read by anyone working in any capacity that involves non-trivial communication.

I also don’t know what American schools you went to, but vocabulary tests were only done in elementary school and a little in middle school in my area. You have to be able to read first in order to understand later :stuck_out_tongue: The tests I took with the exception of foreign language tests had little to nothing to do with memorization during high school and quite a bit more to due with critical thinking and application of knowledge.

California public school. 1990s. Really lousy education. Teach to the tests for the tracked students, no idea what they taught to to the untracked ones but that wasn’t positive either. After four years of advanced English and Math classes I came out not knowing the first thing about grammar or math.

(Since then I have excelled quite well in other areas, so I don’t think it was just me being stubborn. Seriously, 90% of what we did in English classes was talk about how people felt. Incredibly pointless work, no intellectual content at all.)