[plt-scheme] cannot get mapping over procedures (procedure applications) to work
Hi Jon, Hi Will,
thanks a lot for the ultra-quick help! It's clear now.
Ciao,
Sigrid
Am 27.04.2009 um 17:21 schrieb Jon Zeppieri:
>
>
> On Mon, Apr 27, 2009 at 11:16 AM, keydana at gmx.de <keydana at gmx.de>
> wrote:
> Hi all,
>
> this seems like a horribly stupid thing to ask, but I have problems
> to map over procedures (in order to apply them). When I try
>
> (map (lambda (fun) (fun 1 2)) '(* +))
>
> I get
>
> "procedure application: expected procedure, given: *; arguments
> were: 1 2"
>
>
> The problem here is that '(* +) is a list containing the symbols *
> and +, not the functions. You want (list * +) or `(,* ,+).
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.racket-lang.org/users/archive/attachments/20090427/cd8be0e6/attachment.html>