var globalVariable1=0;
//document.write(globalVariable2);
//document.write(localVariable1);
function test1(){
var localVariable1=2
document.write(globalVariable1+"<br/>");
document.write(localVariable1+"<br/>");
}
function welcomeMes(){alert("one");}
//welcomeMes();
var globalVariable2=1;
function test2(){
var localVariable2=3;
document.write(localVariable1+"<br/>");
}
function isLeapYear(year){
if(year%400==0&year%100==0)
{document.write(year+"是闰年");
}
else if(year%4==0&&year%400!=0)
{document.write(year+"是闰年");}
else{document.write(year+"不是闰年");}
}
isLeapYear(2008);
var a=13, b=2, c=5, d=19;
var max;
for(i=0; i<4; i++)
{
if(a<b)
max=b;
else max=a;
if(max<c)
max=c;
if(max<d)
max=d;
}
document.write("<br/>"+"最大的数字是"+max);
console