title: dynamically adding more values to an arraylist in java
body: <p>still a bit new with arrays and lists in java, I would like add elements to a list dynamically, so for example if I had code like this:</p>
  
  <pre><code>List&lt;int[]&gt; rowList = new ArrayList&lt;int[]&gt;();
  
  rowList.add(new int[] { 1, 2, 3 });
  rowList.add(new int[] { 4, 5, 6 });
  rowList.add(new int[] { 7, 8 });
  </code></pre>
  
  <p>how would I dynamically add 1,2,3,4,5,6,7 etc? thanks in advance for the help</p>