Variable name = {symbol: value 1, symbol: value 2} puts variable name [: symbol]
qiita.rb
cat = {name: "siro", age: 23} put cat[:name]
It's similar to js, but the output notation is different, so be careful! : smile:
Recommended Posts