Subject: Re: Cleaner way to do this?
From: Wayne Vucenic <nightphotos gmail.com>
Date: Fri, 5 Nov 2004 10:12:03 +0900
References: 119134
In-reply-to: 119134
How about
[1, 2, 3, 4, 5].each_with_index do |x, i|
if i == 0
print x
else
print ", ",x
end
end
Wayne
-----
No Bugs Software
"Ruby and C++ Contract Programming in Silicon Valley"