Re: FLET vs LABELS
From: Alex Mizrahi (udodenko_at_hotmail.com)
Date: 01/15/05
- Next message: Alex Mizrahi: "Re: FLET vs LABELS"
- Previous message: Trent Buck: "Re: FLET vs LABELS"
- In reply to: Trent Buck: "Re: FLET vs LABELS"
- Next in thread: Jim Newton: "Re: FLET vs LABELS"
- Reply: Jim Newton: "Re: FLET vs LABELS"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Sat, 15 Jan 2005 01:20:49 +0200
(message (Hello 'Trent)
(you :wrote :on '(Fri, 14 Jan 2005 22:39:00 GMT))
(
TB> This brings up another question that occured to me recently: how does
TB> one define a recursive, anonymous function?
using Y operator, for example:
(defun Y (f)
( (lambda (g) (lambda (h) (funcall (funcall f (funcall g g)) h)))
(lambda (g) (lambda (h) (funcall (funcall f (funcall g g)) h)))))
(funcall (Y (lambda (myself) (lambda (n) (if (zerop n) 1 (* n (funcall
myself (- X 1))))))) 10)
or if you don't mind using labels and macros, there are other ways..
see discussion http://tinyurl.com/4ufwo
)
(With-best-regards '(Alex Mizrahi) :aka 'killer_storm)
(prin1 "People, who lust for the Feel of keys on their fingertips (c)
Inity"))
- Next message: Alex Mizrahi: "Re: FLET vs LABELS"
- Previous message: Trent Buck: "Re: FLET vs LABELS"
- In reply to: Trent Buck: "Re: FLET vs LABELS"
- Next in thread: Jim Newton: "Re: FLET vs LABELS"
- Reply: Jim Newton: "Re: FLET vs LABELS"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]