效果图
代码
<!DOCTYPE html>
<html><head><meta charset="utf-8"><title></title></head><body><script type="text/javascript">// 输出乘法口诀表// document.write () 空格 " " 换行 "<br />" 与Html标准相同for (var i = 1; i <= 9; i++) {for (var j = 1; j <= i; j++) {document.write(i + "*" + j + "=" + (i * j) + " ");}document.write("<br />")}</script></body>
</html>
快去试一试吧