M
Max Williams
hey all
I want to pass the contents of an array to a method, to be interpreted
as a standard list of arguments. What's the simplest and nicest way of
doing this? (i can think of a few dirty hack ways but don't want to use
them)
eg
#have
arr = [arg1, arg2, arg3]
#want
a_method(arg1, arg2, arg3)
I want to pass the contents of an array to a method, to be interpreted
as a standard list of arguments. What's the simplest and nicest way of
doing this? (i can think of a few dirty hack ways but don't want to use
them)
eg
#have
arr = [arg1, arg2, arg3]
#want
a_method(arg1, arg2, arg3)