Q. What does the 'attr_accessor' method do in Ruby?
β
Correct Answer: (C)
Defines both getter and setter methods
Explanation: 'attr_accessor' creates both getter and setter methods for instance variables.