This is the mail archive of the guile@cygnus.com mailing list for the guile project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Scheme tutorial


"Ian Bicking" <bickiia@earlham.edu> writes:

> I've been thinking about trying my hand at writing a Scheme/Guile 
> tutorial.  The usual references to the Little Schemer or the Wizard 
> book aren't a good solution, IMHO, because they will put off people 
> with casual interest in Guile.
> 
> The tutorial I'm thinking about would assume that the reader has 
> programmed before, but not in Scheme.
> 
> So, a few questions: is anyone working on this?  Are there any 
> such Schemey tutorials out there that I haven't seen?  Ones that 
> don't start with the much-maligned factorial example?  I haven't 
> read through the various Script-Fu tutorials as much as I should, 
> but they seem to have the right perspective.

I don't think anyone's currently working on this (it would be very
cool, though).
 
> Recommendations for language tutorials that are very well written 
> (for any language)?  I have some ideas about what I think would 
> make a good tutorial, but more inspiration is always good.

I remember that clisp had an ok introduction to lisp included... this
might fall more in the factoral camp, though (I can't remember that
much, but it is what started me on lisp, back when I installed my
first slackware). There seem to be more of this sort of thing
available for cl, actually, so you might want to take a look a the alu
site (I can't quite remember where it is right now... there's a link
to it from the 

> Do people have Guile scripts they'd like to share?  I'd like to get a 
> better feel for what end-user scripts might look like, since they'd 
> probably look a lot different than code that people actually make 
> public.  Examples are everything, and I only have so much 
> imagination to come up with them :-)
> 
> Opinions on how much I should emphasize scripting an application 
> vs. writing a more generic piece of Scheme code?  Is there any 
> application that might be considered a reference work for scripting? 
> I.e., would there be a Guile-scriptable application that could be 
> considered a prerequisite for working through the tutorial, or is that 
> too much to ask from the reader?  Installing any particular 
> application can be a pain, and I'd like to make the tutorial as low-
> commitment as possible.  OTOH, I'd like to have a tutorial where 
> people can do some neat things early on, and scripting an 
> application is a good way to do this.

You might want to include bits of both. For demonstrating scheme,
building a small list library might be a good base, since this would
allow you to naturally introduce things like first-class functions and
tail recursion, as well as most of the primitives (and then extend it
to handle vectors... I have a library partially written that does this
to some extent... it's not the most beautiful piece of hackage,
tho... it's more geared towards giving me a sorta cl environment to
program in, actually). For building a full app, you could probably put
together a simple game like tic-tac-toe.

One thing you definately should make a priority, though, is
continuations, since these are probably the hardest thing to figure
out for newbies to scheme.

-- 
Greg