I'm wondering if its possible to do multidimensional arrays in rails?
I'd like to get something like to formulate some data:
apple => 'tasty', 'red', 'round'
cereal => 'milk', 'breakfast'
name => 'tags'
Where I'm trying to get the name-value pair where the right side is tags so when I call the name, I can get tags.
EDIT:
I currently have this
@array = ['apple', 'cereal', 'name']
But would like to add tags to these
@array = ['apple'=>['tasty', 'red', 'round'], 'cereal' => ['milk', 'breakfast'], 'name' => ['tags']]
I wanted to do something like this, so when I do a loop to output only the names, and the associated tags.