X
Xeno Campanoli
Okay, I'm taking the example I got last week for multi-dimensional hashes, and
I don't have access to any Hash methods:
pHash = lambda { Hash.new {|h,k| h[k] = pHash.call }
pHash['1']['a'] = "one"
p pHash.keys
I run this and get the result:
...undefined method `keys' for ... (NoMethodError)
Do I need to dereference or something, or is this just something that doesn't
work after all?
Sincerely, Xeno Campanoli, Ruby neophyte and general paraphernalian.
I don't have access to any Hash methods:
pHash = lambda { Hash.new {|h,k| h[k] = pHash.call }
pHash['1']['a'] = "one"
p pHash.keys
I run this and get the result:
...undefined method `keys' for ... (NoMethodError)
Do I need to dereference or something, or is this just something that doesn't
work after all?
Sincerely, Xeno Campanoli, Ruby neophyte and general paraphernalian.