Mailing List Archive: 49091 messages
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search
 

[REBOL] Re: Maplist?

From: allenk:powerup:au at: 9-Sep-2001 23:52

----- Original Message ----- From: "Joel Neely" <[joel--neely--fedex--com]> To: <[rebol-list--rebol--com]> Sent: Sunday, September 09, 2001 6:18 PM Subject: [REBOL] Re: Maplist?
> Hi, Ric, and all, > > Ric Gagliardi wrote: > > > > Let me throw my variation in. I found I often used similar > > anonymous functions in map-like situations, so I made a > > variation that uses a block representing the body of the > > function instead: > > > > every: func [ > ... > > ] > > for example, > > > > >> every [a b] [1 2 3 4 5 6] [a + b] > > == [3 7 11] > > > > Very nice! >
Is it intentional to set 'a and 'b in the global context too?
>> every [a b] [1 2 3 4 5 6] [a + b]
== [3 7 11]
>> a
== 5
>> b
== 6 Cheers, Allen K