The Little Schemer 4e by Friedman and Felleisen starts out by defining atom?
:
(define atom?
(lambda (x)
(and (not (pair? x)) (not (null? x)))))
Then in the first chapter there's questions asking if so and so is a atom or not. E.g. (the footnote is rephrased for clarity):
Is it true that this is an atom?
atom
**in Scheme:
(quote atom)
or'atom
It says turkey
, 1492
, u
, and *abc$
are also atoms.
All of these except 1492
must be preceded by a '
- otherwise we get a Error: execute: unbound symbol:
1492
and '1492
both work. Henceforth, in this book, how do I know when something should or should not be preceded by a quote ('
)??? It's confusing. I wish the authors had just been explicit with the quotes -- does it really add that much visual noise to have a single quote ('
) precede expressions??? Should I just assume everything is preceded by a quote ('
)?