<table border='1' id="tabela">
<tbody>
</tbody>
</table>
Would like to print differently
$(document).ready(function(){
var i =0;
while(i< 100){
var resto = i%10;
if(i%10 == 0){
$("tbody").append("<tr>");
}
$("tbody").append("<td>"+i+"</td>");
i++;
//document.getElementById("tabela").innerHtml += "<tr><td>"+i+"</tr></tr>";
if(i%10 == 0){
$("tbody").append("</tr>");
}
}
});
In fact, I wanted to print it this way:
[0] [5] [10] [15] [20]
[1] [6] [11] [16] [21]
[2] [7] [12] [17] [22]
[3] [8] [13] [18] [23]
[4] [9] [14] [19] [24]
How do I do it?