Skip to content

Instantly share code, notes, and snippets.

@hoolymama
Created May 22, 2012 20:40
Show Gist options
  • Save hoolymama/2771488 to your computer and use it in GitHub Desktop.
Save hoolymama/2771488 to your computer and use it in GitHub Desktop.
print date and date + 3 weeks for each week starting june 1st
require 'date'
d = Date.new(2012,6,1)
(0..52).each {|n| puts (d + (n*7)).strftime("%d/%m/%Y") + " "+ (d + ((n+3)*7)).strftime("%d/%m/%Y") }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment