Created
January 16, 2012 06:27
-
-
Save xntrik/1619394 to your computer and use it in GitHub Desktop.
ruby file to print out a sequence of dates .. laaazy
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/ruby | |
require 'date' | |
sd = Date.parse('2011-06-8') | |
ed = Date.parse('2011-06-15') | |
sd.upto(ed) { |date| | |
(0..23).each do |hour| | |
printf("%s:%02d\n",date.strftime('%d/%b/%Y'),hour) | |
end | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment