MCPcopy Create free account
hub / github.com/TheAlgorithms/Go / IsLeapYear

Function IsLeapYear

project_euler/problem_19/problem19.go:55–63  ·  view source on GitHub ↗
(year int)

Source from the content-addressed store, hash-verified

53}
54
55func IsLeapYear(year int) bool {
56 if year%4 == 0 {
57 if year%100 == 0 {
58 return year%400 == 0
59 }
60 return true
61 }
62 return false
63}

Callers 1

Problem19Function · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected