Search code examples
schemelispquotethe-little-schemer

What is ' (apostrophe) in Lisp / Scheme?


I am on day 1 hour 1 of teaching myself Scheme. Needless to say, I don't understand anything. So I'm reading The Little Schemer and using this thing:

http://sisc-scheme.org/sisc-online.php

as an interpreter.

I need to use ' in for example

(atom? 'turkey)

to avoid an "undefined variable" error. The ', according to the book, is a Common Lisp thing.

I have two questions:

  1. Is the interpreter I mentioned above a good one? Can you recommend another? I need one that will go well with The Little Schemer.

  2. What is '?


Solution

  • The form 'foo is simply a faster way to type the special form

    (quote foo)
    

    which is to say, "do not evaluate the name foo replacing it with its value; I really mean the name foo itself".

    I think SISC is perfectly fine for exploring the exercises in TLS.