Newsgroups: comp.lang.scheme
Path: cantaloupe.srv.cs.cmu.edu!bb3.andrew.cmu.edu!newsfeed.pitt.edu!gatech!newsfeed.internetmci.com!news.kei.com!nntp.coast.net!harbinger.cc.monash.edu.au!news.mel.connect.com.au!munnari.OZ.AU!newsroom.utas.edu.au!ml.csiro.au!news
From: gray@heimdal.ml.csiro.au (Randall Gray)
Subject: Re: lisp resistance: lack of visual cues?
In-Reply-To: Tom Christiansen's message of 9 Jan 1996 01:33:22 GMT
X-Nntp-Posting-Host: heimdal
Message-ID: <u1wx6ufndv.fsf@heimdal.ml.csiro.au>
Lines: 59
Sender: gray@heimdal.ml.csiro.au
Organization: CSIRO Marine Labs.
X-Newsreader: Gnus v5.1
References: <4bjskn$o6b@jive.cs.utexas.edu>
	<DKo6wD.Lox.0.macbeth@cogsci.ed.ac.uk> <4cjsqm$ei@jive.cs.utexas.edu>
	<DKvr14.2u6.0.macbeth@cogsci.ed.ac.uk>
	<4csgl2$5se@csnews.cs.colorado.edu>
Date: Sun, 14 Jan 1996 21:59:56 GMT

In article <4csgl2$5se@csnews.cs.colorado.edu> 
	Tom Christiansen <tchrist@mox.perl.com> writes:

   One theory is that having all bracketing constructs be parens provides
   little visual distinction to remind the reader what's going on.  The
   visual queues are stronger in languages where round brackets are used for
   one thing, square brackets for another, curly brackets for still another,
   and perhaps even angle brackets for yet another thing.

	<snip>


I think Tom has put in a good point.  I came to scheme comparatively
late in life.  I *had* to learn it since it was the lingua franca in a
course.  Before that I programmed in mainly in C or pascal and avoided
anything that had even a vague similarity to Lisp.

On reflection, I think that this may be due to the lack of cues: when
one looks at an Algol-like syntax one sees a structure inherent in the
"words" that make it up.  Looking at a <lisp family> program can be
like looking at line noise -- lots of repeated characters interspersed
with what may or may not be random characters.

In terms of enjoyment, I *enjoy* scheme in a way I can never enjoy C
(and certainly never enjoy C++).  I prefer to parse scheme-like
configuration files, produce parenthesis grouped output files, etc,
etc.

I really enjoy scheme, but the parens *did* put me off at first.  Of
course I now don't mind them as much, but I still find scheme *much*
harder to read -- I believe that this *is* due to the lack of
contextual cues.  Thus, one of the things that makes scheme so
wonderfully simple is also one of the things that makes it harder.

I put it down to the same sort of problem that crops up with
mathematical theorems: A really general theorem that applies almost
anywhere often has virtually no leverage while a really specific
theorem that you have to struggle to meet the preconditions for gives
you a plumber's friend as big as the moon.  

_Right_ in one context isn't just "not the same" as _right_ in another
context: it is incompatible.

Give me a tool for the job: I don't want to drive nails with a
screwdriver.  I think scheme is rather nicer when you *can* mix
grouping pairs (ie () [] and {}).  My choice would be for {} to group
things like lets and ifs, [] to group arg parts and () for the rest).

{let wobble [(wobbles-eaten 0) (wobbles-remaining 20)]
	{if (not (zero? wobbles-remaining))
	    {begin
		(display "There are no wobbles left\n")}
	    (wobble (1+ wobbles-eaten) (1- wobbles-remaining))}}


Of course your mileage may approach zero, but just my thoughts on the
matter.

-- Randall

-- 
___________________________________________________________________
Randall Gray	gray@ml.csiro.au        CSIRO Division of Fisheries
