How can I calculate the day of the week of a date in Ruby? For example, October 28 of 2010 is = Thursday
As @mway said, you can use date.strftime("%A") on any Date object to get the day of the week.
If you're lucky Date.parse might get you from String to day of the week in one go:
def weekday(date_string)
Date.parse(date_string).strftime("%A")
end
This works for your test case:
weekday("October 28 of 2010") #=> "Thursday"