|
 |
Invisible escreveu:
>>> Yes, Scheme is a Lisp dialect. No, I quite don't understand why it'd
>>> be such a PITA. :)
>>
>> Something about dozens of parenthesis...
>
> (if (= 1 x) (lambda (n) (1)) (lambda (n) (+ 1 n)))
I don't really think someone scripting Gimp needs lambdas. And your
first lambda will fail because 1 is not a function, but you've put it in
calling context as the first element of a list.
Other than that, "if" is as straightforward as in any language.
(if condition
this
that)
or just
(if condition this)
Actually, the "if-then-else" statement was born in Lisp.
Post a reply to this message
|
 |