Node:Syntax Summary, Previous:The REPL, Up:About Expressions
This subsection lists the most commonly used Scheme syntactic expressions, simply so that you will recognize common special syntax when you see it. For a full description of each of these syntaxes, follow the appropriate reference.
lambda
(see Lambda) is used to construct procedure objects.
define
(see Top Level) is used to create a new variable and
set its initial value.
set!
(see Top Level) is used to modify an existing variable's
value.
let
, let*
and letrec
(see Local Bindings)
create an inner lexical environment for the evaluation of a sequence of
expressions, in which a specified set of local variables is bound to the
values of a corresponding set of expressions. For an introduction to
environments, see See About Closure.
begin
(see begin) executes a sequence of expressions in order
and returns the value of the last expression. Note that this is not the
same as a procedure which returns its last argument, because the
evaluation of a procedure invocation expression does not guarantee to
evaluate the arguments in order.
if
and cond
(see if cond case) provide conditional
evaluation of argument expressions depending on whether one or more
conditions evaluate to "true" or "false".
case
(see if cond case) provides conditional evaluation of
argument expressions depending on whether a variable has one of a
specified group of values.
and
(see and or) executes a sequence of expressions in order
until either there are no expressions left, or one of them evaluates to
"false".
or
(see and or) executes a sequence of expressions in order
until either there are no expressions left, or one of them evaluates to
"true".