Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

how to print 1 to 10 table in javascript

console.log("<table><thead><tr><th>#'s 1 to 10</th></tr></thead>");
for(let i=1; i < 11; i++){
	console.log("<tr><td>" + i + "</tr></td>");
}
console.log("</table>");
 
PREVIOUS NEXT
Tagged: #print #table #javascript
ADD COMMENT
Topic
Name
7+4 =