Format a date like 1st, 2nd, 3rd Source: [Helper to print numbers as ordinals (1st, 2nd, 3rd...)](http://snippets.dzone.com/posts/show/593) class Fixnum def ordinal self.to_s + ( (10...20).include?(self) ? 'th' : %w{ th st nd rd th th th th th th }[self % 10] ) end end d = Time.now.day puts 'today is the ' + d.ordinal #=> today is the 10th date format ordinals