[TUHS] 80 columns ...

Dan Cross crossd at gmail.com
Thu Nov 9 07:19:49 AEST 2017

On Wed, Nov 8, 2017 at 4:02 PM, Larry McVoy <lm at mcvoy.com> wrote:
> On Wed, Nov 08, 2017 at 08:52:03PM +0000, ron minnich wrote:
>> So, 80 column folks, would you find this
>> a(b,
>> c,
>> d)
>> more readable than
>> a(b,c,d)
> yeah, I do.  I work on thinkpad x220 sized machines which are just big enough
> for two 80 column windows with a little left over.  When I'm checking in code,
> reviewing code, debugging code, I frequently want to see two versions of the
> same file side by side.  If you code wider than 80 columns it greatly reduces
> the speed at which you can figure out what happened.

The thing that sort of vexes me about these arguments is that the
number 80 is so arbitrary. If you can fit two 80 column windows
side-by-side, then surely you could do the same with two 78-, 72- or
even 64-column windows. So why not 64, 72 or 78 columns?

Being tethered to a 1960s hardware standard has always struck me as
odd and the justifications have an "after-the-fact" quality to them.
Sure, 80-columns seems to be approaching some cognitive optimum, but
when I see things like deliberate misspellings or grammar errors to
keep a comment under the 80-column maximum, I feel like something's

My own feeling is that programmers should be given some latitude to
make the correct decision in this domain, and that individual excesses
should be addressed in the code review process. That said, I once
worked in a code base (in Common Lisp, no less!) where the standard
was 100 columns, but this was frequently exceeded (I think I measured
that, out of a half-million or so lines of CL, something like 10% were
longer than 100 characters).

> So the question isn't what you said above, it's do you want to have to
> reach for the horizontal scrollbar constantly?  Maybe you do, I don't.

I think this is the wrong question: why would it be constantly? Even
in code-bases with longer code limits, I claim that the vast majority
of lines should be far less than the limit. What's the median line
length? 90% percentile? Etc.

> And you could say "get a higher res screen" which I'm doing, my 1920x1600
> carbon x1 is on the way.  But
>         (a) I still have lots of x220, x230 screens that are useful
>         (b) I can't see a font smaller than what I'm using, the x1
>             will be 2 80 column windows next to each other.

I'll bet that you could get two 82-column windows side-by-side. :-)
Larry, I'll buy you a beer the next time I'm on the west coast if you

> All of this boils down to "do you optimize for the reader or optimize for
> the writer".  Ron wants writer, I want reader.  Write once, read many.

I'm not sure I would characterize it that way. I think we all want
reader, but we just differ in how we want to get there.

        - Dan C.

More information about the TUHS mailing list