title: How do I create an Array or ArrayList with a looped, column of strings that contain integers?
body: <p>I have tried so hard to find a solution to this problem! Here is my code:</p>
  
  <pre><code>import java.io.*;
  import java.lang.reflect.Array;
  import java.util.ArrayList;
  
  public class Weather {
      public static void main(String[] args) throws IOException {
          //Getting the file.
          String fileName = "weather2013.txt";
  
          //Lines!
          String line;
  
          //Creating arrayList object
          ArrayList aList = new ArrayList();
          try {
              BufferedReader input = new BufferedReader(new FileReader(fileName));
              while ((line = input.readLine()) != null) {
                  aList.add(line);
              }
              //Close the file
              input.close();
  
          } catch (FileNotFoundException ex) {
              System.out.println("File not found!");
          }
  
          //Station ID Number:
          String firstLine = aList.get(1).toString();
          String stationIDStr = firstLine.substring(0, 6);
          int StationID = Integer.parseInt(stationIDStr);
          //System.out.println(StationID);
  
          //WBAN ID Number:
          String wbanIDstr = firstLine.substring(7, 12);
          int wbanID = Integer.parseInt(wbanIDstr);
          //System.out.println(wbanID);
  
          //Year!
          String yearStr = firstLine.substring(12, 18).trim();
          int year = Integer.parseInt(yearStr);
          //System.out.println(year);
  
          //Remove line of text (not needed)
          aList.remove(0);
  
          //Fog days:
          int fogDays = 0;
          for (int i = 0; i &lt; aList.size(); i++) {
              String listString = aList.get(i).toString(); //iterate each readLINE -&gt; String
              String lastDigits = listString.substring(132, 137); //Each entry from 132-137 only
              char fogIndicator = lastDigits.charAt(0);
              if (fogIndicator == '1') {
                  fogDays++;
              }
          }
          //System.out.println(fogDays);
  
  
          //Maximum and minimum average temps
          for (int i = 0; i &lt; aList.size(); i++) {
              String listString = aList.get(i).toString();
              String averageTempDigits = listString.substring(24, 30).trim();
          }
      }
  }
  </code></pre>
  
  <p>The specific part of the code where I am having trouble is the VERY last for loop.
  Here's what's being outputted:</p>
  
  <pre><code>    47.9
      41.8
      .
      .
      .
      .
      41.8
      67.0
      66.5
  </code></pre>
  
  <p>I would like to know how to get this column above into an Array or ArrayList?</p>