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

[REBOL] Passing hash keys to functions

From: premshree::pillai::gmail::com at: 29-Dec-2004 2:35

Hi, I'm trying to write a function that accepts a key as an argument, and then returns the corresponding value. Some code: hsh: make hash! [] append hsh [a [1 2] b [3 4]] get-val: func [of no] [ print hsh/#of/#no ] the get-val function above accepts two arguments. If I pass a and 1 as the argument it should return the value of hsh/a/1. Thoughts? -- Premshree Pillai