Is it possible to write a nested for loop that builds a table and where the perfect squares are in bold?
I have this much now
<table border=1 cellpadding=10>
<script type="text/javascript">
for (j=1; j<=10; j++) {
document.write('<tr>');
for (i=1; i<=10; i++) {
document.write('<td align ="center">',i*j,'</td>');
}
document.write("</tr>\n");
}
</script>
But I want to highlight the perfect squares in the table.
Does anyone
http://jsfiddle.net/mmhDR/
jis often used as the second loop variable,kafter that, etc.edit: Using document.write():
http://jsfiddle.net/8vTg7/