I need to index into a hash that I have defined in terms of "true" and "false"
colorHash = Hash.new { |hash, key| hash[key] = {} }
colorHash["answers"][true] = "#00CC00"
colorHash["answers"][false] = "#FFFFFF"
For testing purposes, I am indexing with rand(2) and that fails. If I index with true it works.
I was looking for something like
rand(2).logical
but find nothing.