(java) set size of a vector
<p>I am facing a very simple issue : </p>

<pre><code>List&lt;String&gt; myList = new Vector&lt;String&gt;(10);
myList.add(5,"HELLO");
</code></pre>

<p>gives me <code>ArrayOutOfBoundException : 5&gt;0</code></p>

<p>Is there a way to specify the size of a Vector and fill the list in random order?</p>