Examveda

What is the difference between a class method and an instance method in Ruby?

A. Class methods are called on the class itself, while instance methods are called on instances of the class

B. Instance methods are called on the class itself, while class methods are called on instances of the class

C. Class methods are public, while instance methods are private

D. Instance methods are public, while class methods are private

Answer: Option A


Join The Discussion

Related Questions on Object Oriented Programming (OOP) Concepts in Ruby