Examveda

How do you pass arguments to a method in Ruby?

A. method_name(arg1, arg2)

B. method_name { arg1, arg2 }

C. method_name.with(arg1, arg2)

D. method_name arg1 arg2

Answer: Option A


This Question Belongs to Ruby Programming >> Basic Syntax In Ruby

Join The Discussion

Related Questions on Basic Syntax in Ruby