Skip to content

Comment on Nobody Hates Software More Than Software Developersparent

Comments

Some of these "violations" are good ideas in some contexts. Tom Duff has written a pretty good, clear case for "single entry, multiple exit" in the form of multiple conditional return statements in a function. And Rob Pike has made a pretty clear case that this:

        for(i=0 to 100)
                array[i]=0;
is better than this:
        for(elementnumber=0 to 100)
                array[elementnumber]=0;
But that involves variables named with 1 or 2 characters.

The rest I pretty much agree with, except in very unusual cases.

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.