I learned from Access nested hash element specified by an array of keys)
that if i have a array
array = ['person', 'age']
and I have a nested hash
hash = {:person => {:age => 30, :name => 'tom'}}
I can get the value of of age by using
array.inject(hash, :fetch)
But How would I then set the value of :age to 40 with the array of keys?