M Mr. Dubey • 100.28K Points Coach Bookmark Embed Report View In MB-Short Q. What is the purpose of the attr_accessor method in Ruby classes? (A) Defines only a reader method for class attributes (B) Defines only a writer method for class attributes (C) Defines constructor methods for class attributes (D) Defines both reader and writer methods for class attributes Correct Answer - Option(D) Views: 110 Filed under category Ruby Share
Discusssion
Login to discuss.