16 lines
421 B
Plaintext
16 lines
421 B
Plaintext
( leap-year
|
|
=
|
|
. mod$(!arg.100):0
|
|
& `(mod$(!arg.400):0) { The backtick skips the remainder of the OR operation,
|
|
even if the tested condition fails. }
|
|
| mod$(!arg.4):0
|
|
)
|
|
& 1600 1700 1899 1900 2000 2006 2012:?tests
|
|
& whl
|
|
' ( !tests:%?test ?tests
|
|
& ( leap-year$!test&out$(!test " is a leap year")
|
|
| out$(!test " is not a leap year")
|
|
)
|
|
)
|
|
& ;
|