title: JSP use contents of an array list in a drop down box
body: <p>I have an <code>arraylist</code> that is declared and populated in a <code>JSP</code> file:</p>
  
  <pre><code>&lt;% for(int i=0; i&lt; GDI.getRow(); i++){
      associatedLines[i] = GDI.getRow().get(i).getNumplanindex;
  }
  
  ArrayList&lt;Integer&gt; availableLines = new ArrayList&lt;Integer&gt;();
  for(int i=0; i&lt;associatedLines.length; i++){
      if(associatedLines[i] == null){
           availableLines.add(i);
      }
  }
  
  %&gt;
  </code></pre>
  
  <p>I would like to use the contents of <strong>availableLines</strong> in the dropdown list and be able to store the value selected to be used somewhere else.</p>
  
  <p>I am almost certain that I need to use <code>JSTL</code> but I am not sure how to do it.</p>
  
  <p>Hopefully somebody can help. Thanks!</p>