Skip to content

Instantly share code, notes, and snippets.

@rockBreaker
Last active August 29, 2015 14:03
Show Gist options
  • Save rockBreaker/8311c67b8045357e3229 to your computer and use it in GitHub Desktop.
Save rockBreaker/8311c67b8045357e3229 to your computer and use it in GitHub Desktop.
crappy leap year thing
(defn divides?
[div n]
(= (mod n div) 0))
(defn guy-year2?
[year]
(if (divides? 400 year)
true
(if (divides? 100 year)
false
(if (divides? 4 year)
true
false))))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment