What is the purpose of the Enumerator class in Ruby?
A. It provides a way to enumerate over the elements of an array
B. It allows you to create custom iterators for any enumerable object
C. It allows you to define custom iteration behavior for any enumerable object
D. None of the above
Answer: Option B

Join The Discussion