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

[REBOL] Associative data store Re:(5)

From: al:bri:xtra at: 18-Sep-2000 16:48

Gabriele wrote:
> Andrew wrote: > A> And here's a version that's shorter and nicer to use. Can any one
think of a shorter version?
> Yup. ;^) > > associate: func [block [block!] key value] [ > head change/only any [ > find/tail block key > insert tail block key > ] reduce [val] > ] > > associate?: func [block [block!] key] [ > all [key: select block key first key] > ]
Thanks Gabriele! I just need to change this line: ] reduce [val] to: ] reduce [value] as there's a stray 'VAL running around in Rebol. Andrew Martin That Val is not my sister! :-) ICQ: 26227169 http://members.ncbi.com/AndrewMartin/ http://members.xoom.com/AndrewMartin/