JS var count = 0; for (var i = 1; i <= 9; i++) { for (var k = 1; k <= i; k++) { document.write(k + "x" + i + "=" + i * k + " "); } document.write("<br>"); document.write("<br>"); } 打印结果