上一篇 | 下一篇

闰年的判别

发布: 2008-6-27 11:50 | 作者: admin | 来源: | 查看: 0次

闰年判别

<%

if Request.Form("cal")="y" then

n=Cint(Request.form("me"))

if ((n mod 4=0) and (n mod 100<>0)) or (n mod 400=0) then

Response.Write n & "是闰年!
"

else

Response.Write n&"不是闰年。
"

end if

end if

%>

输入年份:

字号: | 推荐给好友

评分:0

我来说两句