<!DOCTYPE html>
<HTML lang="ja">
<head>
<meta charset="UTF-8">
<title>掛け算九九対応表</title>
<style>
th{
background-color:#CCC;
width:60px;
}
td{
text-align:right;
width:50px;
}
</style>
</head>
<body>
<h3>掛け算九九表</h3>
<table border="2">
<tr></tr>
<tr>
<?php
print('<th></th>');
for ($t = 1; $n < 10; $n++) {
print('<th>'.$n.'</th>');
}
?>
</tr>
<?php
for ($i = 1; $i < 10; $i++) {
print('<tr>');
print('<th>'.$i.'</th>');
for ($j = 1; $j < 10; $j++) {
print('<td>'.($i * $j).'</td>');
}
print('</tr>');
}
?>
</table>
</body>
</html>