From: Patrick Doyle Date: 2008-09-20T10:53:42+09:00 Subject: Re: [QUIZ] One-Liners Mashup (#177 again) On Fri, Sep 19, 2008 at 9:21 PM, Daniel Moore wrote: > def repeat(i) > r = []; each { |x| r.push(*([x] * i)) }; r > end > Here's mine: def repeat(i) self.map {|x| [x] * i}.flatten end I don't appreciate Ruby syntax enough to understand the significance of the *(...) construct in Daniel's solution. What does that do? Can you show an example where the results are different than my solution? --wpd