Skip to content

Instantly share code, notes, and snippets.

@ptzn
Created January 14, 2011 16:44
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ptzn/779852 to your computer and use it in GitHub Desktop.
Save ptzn/779852 to your computer and use it in GitHub Desktop.
IRB session with date format difference in ruby 1.9 & 1.8
# ruby 1.9.2
> Date._parse("11/15/2010", false).values_at(:year, :mon, :mday)
=> [2010, 15, 11]
# ruby 1.8
> Date._parse("11/15/2010", false).values_at(:year, :mon, :mday)
=> [2010, 11, 15]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment