Also, it would be clearer to write something like this:

results = []

Saturday = 6
Sunday = 7
Weekend = [Saturday, Sunday]
....
....

  while Weekend.include?(first_day_of_month.wday)
    first_day_of_month += 1
  end

-- 
Posted via http://www.ruby-forum.com/.