RosettaCodeData/Task/Leap-year/PostScript/leap-year.ps
Ingy döt Net d066446780 langs a-z
2013-04-10 22:43:41 -07:00

10 lines
180 B
PostScript

/isleapyear {
dup dup
4 mod 0 eq % needs to be divisible by 4
exch
100 mod 0 ne % but not by 100
and
exch
400 mod 0 eq % or by 400
or
} def