Max Williams wrote: > 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) Look up the splat operator, a.k.a. unary unarray: a_method(*arr) -- RMagick: http://rmagick.rubyforge.org/