title: Array integer Android
body: <p>ok so i create an array that has integers. The array displays five number from the min and max. How can i display all five numbers in a textview or edittext ? I tried:</p>
  
  <pre><code>nameofile.setText(al.get(x).toString()); 
  </code></pre>
  
  <p>but it only displays one?</p>
  
  <pre><code>ArrayList&lt;Integer&gt; al = new ArrayList&lt;Integer&gt;();
  for (int i = minint; i &lt;= maxint; i++)
      al.add(i);
  
  Random ran = new Random();
  
  for (int i = 0; i &lt; 5; i++) {
      int x = al.remove(ran.nextInt(al.size()));
      String myString = TextUtils.join(", ", al);
      lottonumbers.setText(myString);
  </code></pre>