Home > Article > Web Front-end > JavaScript implements 99 multiplication table code
This article mainly introduces you to the relevant information of using JavaScript to implement a small program 99 multiplication table. Friends who need it can refer to it. I hope it can help you.
<!DOCTYPE html> <html> <head> <title>99乘法表</title> <meta charset="utf-8"> </head> <body> <script type="text/javascript"> for (var i = 1; i <= 9; i++) { for (var j = 1; j <= i; j++) { document.write(i+'*'+j+'='); document.write(i*j+' '); } document.write("<br/>"); } </script> </body> </html>
The renderings are as follows:
An example of using double-layer loops to implement multiplication tables in PHP
JavaScript loop practice methods of printing triangles, factorials, and multiplication tables
shell script Implemented multiplication table example
The above is the detailed content of JavaScript implements 99 multiplication table code. For more information, please follow other related articles on the PHP Chinese website!