Skip to content

Instantly share code, notes, and snippets.

@graybill
Created July 13, 2012 16:15
Show Gist options
  • Save graybill/3105751 to your computer and use it in GitHub Desktop.
Save graybill/3105751 to your computer and use it in GitHub Desktop.
def last_quarter
x = (Date.today.strftime('%m').to_f / 12 * 100).to_i
y = 25; i = 0
while x > y do
y += 25; i += 1
end
quarters[i]
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment