|
|
|
LEAP YEAR
Added on 5/27/2001
|
This is a way to calculate if a year is a leap year, or a regular year...
Download PC Source Download Mac Source
---------------------------------------------------------------------------------------------------
---------------------------------------------------------------------------------------------------
-- LEAP YEAR
--
-- This is a way to calculate if a year is a leap year, or a regular year...
--
--
--
-- Kurt * Belgium 2001
--
---------------------------------------------------------------------------------------------------
---------------------------------------------------------------------------------------------------
on mouseup me
--Use fields for In-and Output
vYear = (member "Input").text.integer
vLeap = "a regular year"
if vYear mod 4 = 0 then
vLeap = "a leap year"
end if
if vYear mod 100 = 0 and vYear mod 400 <> 0 then
vLeap = "a regular year"
end if
put vYear&","&& vLeap into (Member "Output")
end
|
|