Dividing items into columns
<p>I have a dynamic number of items to divide into a maximum of 4 columns, with the proper html format surrounding then, lets say:</p>

<pre><code>string[] s = { "1", "2", "3", "4", "5", "6", "7", "8", "9" }; // from 1 to n itens
</code></pre>

<p>To format into this html:</p>

<pre><code>&lt;ul&gt;
  &lt;li&gt;
     1
     2
     3
  &lt;/li&gt;
  &lt;li&gt;
     4
     5
  &lt;/li&gt;
  &lt;li&gt;
     6
     7
  &lt;/li&gt;
  &lt;li&gt;
     8
     9
  &lt;/li&gt;
&lt;/ul&gt;
</code></pre>

<p><strong>Edit: my website problem:</strong></p>

<p>If you have words as itens, putting the itens this way will organize the words into alphabetically columns (people read this way), not alphabetically rows. Like:</p>

<pre><code>a d g i
b e h j
c f 
</code></pre>

<p>Instead of:</p>

<pre><code>a b c d
e f g h
i j
</code></pre>
