Learn
Remember when we covered loops and iterators? We could use a whole bunch of different methods for looping in a program. When we loop over an array or a hash, we say that we iterate over it.
We’ll be using the .each
iterator to iterate over arrays and hashes in this section. Take a look at the code in the editor to see one example of how we might go about this.
Instructions
When you think you understand the code in the editor, click Run to see it in action.
Take this course for free
By signing up for Codecademy, you agree to Codecademy's Terms of Service & Privacy Policy.