JAVASCRIPT中将1-100之间的偶数输出

2024-10-29 03:45:22
推荐回答(2个)
回答1:

var b=1;
while(b<101)
{
if(b%2==0)
document.write("#."+b+" ");
if(b%20==0)
document.write("
");
b++;
}

回答2: