Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
pub fn is_leap_year(year: i32) -> bool {
(year % 4) == 0 || (year % 100 == 0 && year % 400 == 0)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment