JQuery/JavaScript - Creating a table from list of words
<p>At the moment this creates the table for the list of words, but only in one column. How do I get it to print into a 4x5 table? </p>

<pre><code>var listOfWords = ["mat","cat","dog", "pit", "pot", "fog", "log", "pan", "can", "man"];
var innerTable = '';
for (var i = 0, len = listOfWords.length; i &lt; len; i++) {
innerTable += '&lt;tr&gt;&lt;td&gt;'+listOfWords[i]+'&lt;/td&gt;&lt;/tr&gt;';
}
$('&lt;table&gt;'+innerTable+'&lt;/table&gt;').appendTo('body');
</code></pre>
