9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
From: "Russ Cox" <rsc@plan9.bell-labs.com>
To: 9fans@cse.psu.edu
Subject: Re: [9fans] code complexity
Date: Tue,  5 Feb 2002 11:34:51 -0500	[thread overview]
Message-ID: <37088672ac32055400db1684d3dfae65@plan9.bell-labs.com> (raw)

I don't really feel like most of those line counts
are comparable, since it's not clear how much is 
there.  If you want something else that is not
really comparable, note that the TeX add-on package
for Plan 9 is almost the same size as the "everything else"
base package.

As for why, there certainly exists a small class of programmers
that actively believes writing complex programs is
just macho.  To them, I admit: I am not man enough to
keep up with your layers upon layers of complexity.
When I run into code they have written, I inevitably
complain to whoever will listen until I get fed up
enough to rewrite it.  To some extent, Mel is in this
class, although he understands programs as craft too.

At the same time, I think most programmers just don't
understand that programs are intended to be read by humans.
They fiddle until it works and then don't see the point
to doing it over again in a cleaner, simpler, more elegant
manner.  Especially if someone is being measured by some
bogus productivity metric like like lines of code written,
papers published, or problem sets handed in.

Good programming is like good writing in any subject;
it happens only by much revision and practice.  The sad
thing is that at least in my experience, introductory
programming courses just don't get that across.  (In fact,
in my experience most writing courses state that but then
do a poor job of backing it up.)  I helped to teach an
introductory computer science theory course for three years,
and we had the same problems there.  Students didn't
see any point to distilling a correct yet awkward proof
down to its essence; after all, it was correct, wasn't it?
(I don't know if this was natural or they got it from
taking intro to programming the year before.)
Even so, we didn't give much opportunity to help
them rewrite their proofs.  We did hand out the best
most elegant proofs we had on the solution sets,
and I think that helped somewhat, but I'm still not
sure how many internalized the message.

End of rant.
Russ


             reply	other threads:[~2002-02-05 16:34 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2002-02-05 16:34 Russ Cox [this message]
2002-02-05 16:39 ` Boyd Roberts
2002-02-05 16:42   ` Ronald G Minnich
2002-02-05 17:20     ` david presotto
2002-02-05 23:06       ` Steve Kilbane
2002-02-05 20:24 ` philw
2002-02-06  1:01   ` ozan s yigit
2002-02-05 22:28 ` Dan Cross
  -- strict thread matches above, loose matches on Subject: below --
2002-02-06  0:10 [9fans] XP (was: code complexity) geoff
2002-02-06  0:29 ` [9fans] code complexity George Michaelson
2002-02-06 10:47   ` Boyd Roberts
2002-02-06 20:49     ` Andrew Simmons
2002-02-05 16:41 Russ Cox
2002-02-05 14:24 Richard Uhtenwoldt
2002-02-05 14:47 ` Matt H

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=37088672ac32055400db1684d3dfae65@plan9.bell-labs.com \
    --to=rsc@plan9.bell-labs.com \
    --cc=9fans@cse.psu.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).