From: "Sébastien Durand" Date: 2013-04-28T00:01:43+09:00 Subject: Re: Tap method : good or bad practice ? Thank you very much for your various answers ! :-) Why this kind of loop from 1 to 31 ? These magic numbers are the days in a month and I use them in a DaySelect class. I decided to go with the most explicit implementation : def options options = {} '1'.upto('31') do |day| options[day] = '%02d' % day end options end "tap", "each_with_object" and so on are maybe overkill ? But being new to Ruby, this makes me realize that there is more than one way to do it and Ruby fits everybody's style. (By the way, sorry for my poor english, I'm a french-speaking guy.) -- Posted via http://www.ruby-forum.com/.