Skip to content

Instantly share code, notes, and snippets.

@lordhumunguz
Created March 7, 2013 20:00
Show Gist options
  • Save lordhumunguz/5111273 to your computer and use it in GitHub Desktop.
Save lordhumunguz/5111273 to your computer and use it in GitHub Desktop.
This gist has been created from CodeCred.me
def leap_year? (year)
if year%100 == 0 && year%400 == 0
puts "Leap Year!"
elsif year%4 == 0 && year%100 != 0
puts "Leap Year!"
else
puts "Not Leap Year!"
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment