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

[REBOL] Re: I just ain't gettin' it! :)

From: carl:cybercraft at: 20-Dec-2002 12:42

On 20-Dec-02, Ed Dana wrote:
> [SunandaDH--aol--com] wrote: >> One way is 'poke (just like good old fashioned Basic): >> x: [ 1 2 3 4 ] >> index: 3 >> ;; replace a value >> poke x index 5 >> == [1 2 5 4] >> ;; do something to a value: >> poke x index x/:index * 2 >> == [1 2 10 4] > That's the ticket! > Exactly what I was looking for. > Thanks, Sunanda. :)
Note however that the opposite isn't peek, but...
>> pick [a b c d e] 3
== c (: -- Carl Read