25.11.2014 Views

Tema Lisp - Dpto. Ciencias de la Computación e Inteligencia Artificial.

Tema Lisp - Dpto. Ciencias de la Computación e Inteligencia Artificial.

Tema Lisp - Dpto. Ciencias de la Computación e Inteligencia Artificial.

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Variables locales<br />

* (LET ((VAR-1 VAL-1)...(VAR-M VAL-M)) E-1 ... E-N)<br />

(setf a 9 b 7) => 7<br />

(let ((a 2)(b 3)) (+ a b)) => 5<br />

(+ a b) => 16<br />

(let ((x 2)(y (+ 1 x))) (+ x y)) => Error<br />

* (LET* ((VAR-1 VAL-1) ... (VAR-N VAL-N)) E-1 ... E-M)<br />

(let* ((x 2)(y (+ 1 x))) (+ x y)) => 5<br />

IA-I 2003–2004 CcIa Introducción a <strong>Lisp</strong> <strong>Lisp</strong>.48

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!