摘要:
/*id和table*/#a{ background-color:green; width:400px; height:300px;}tr{ background-color:pink;}td{ color:gray;}/*class*/.a{ color:red; font-size:20px;}/*class和id混合*/.d{font-size:15px; background-color:green; font-style :italic ;}#b,#f{ color:yellow; background:red;}.h{ text-transform:capita... 阅读全文
摘要:
document.write("九九乘法表:"); document.write("<br>"); for(i = 1; i<10;i++){ for(j = 1; j<=i;j++){ var result = i*j; document.write( j + "*" + i + "=" + result +" " ); } document.write("<br>"); } 阅读全文
摘要:
153/100 (153-1*100)/10 153-1*100-5*10 */ document.write("100---999之间的水仙花数为:"); document.write("<br>"); for(i = 100; i < 1000;i++){ var num1 = Math.floor(i/100); var num2 = Math.floor((i - num1*100)/10); var num3 = Math.floor(i-(... 阅读全文
摘要:
document.write("1000以内的奇数为:"); document.write("<br>"); for(i = 0 ; i<1000; i ++){ if( i % 2 ==1){ document.write( i + " "); } } 阅读全文