The “dig” method
Learn what the dig method is and how to use it in Ruby.
We'll cover the following...
Iteration over nested data structure
Let’s look at the following nested data structure:
users = [
{ first: 'John', last: 'Smith', address: { city: 'San Francisco', country: 'US' } },
{ first: 'Pat', last: 'Roberts', address: { country: 'US' } },
{ first: 'Sam',
...