An Enumerator is a class which allows both internal and external iteration. Most methods have two forms: a block form where the contents are evaluated for each item in the enumeration, and a non-block form which returns a new Enumerator wrapping the iteration.
Early on in my coding journey, I found remembering all of the array commands pretty challenging. So I thought I’d put together a cheat sheet for anyone who is going through the same thing or anyone who just needs an quick reference. I found an excellent source on this so I’ll link that below!
Iteration pretty much blew my mind. Enough that learning these concepts made me wonder if my mind was even still there afterwards. My initial relationship with Procedural Ruby was frustrating, to say the least. After reading through all the material, completing the labs, taking notes, and reviewing everything, I finally really appreciate everything that iteration can do. From what I can tell though, it’s a common topic to get confused on. So for anyone out there still struggling through it, I’ve collected my favorite notes from my lessons at Flatiron School and a few online articles to help you understand these concepts!
I am relentless.
Coding could have saved me so much agony!