Totalling up numbers within ArrayList out displaying
<p>I want to output the total of some numbers in a text file, with the use of an <code>ArrayList</code> to seek them out etc, I am unsure of how I would do this? here is my code:</p>

<pre><code>import java.io.File;
import java.io.FileNotFoundException;
import java.util.ArrayList;
import java.util.Scanner;

public class ArrayListOfNumbers {

    public static void main(String[] args) throws FileNotFoundException {
        ArrayList&lt;String&gt; numbers = new ArrayList&lt;String&gt;();
        Scanner Scan = new Scanner (new File("numbers.txt"));

        while (Scan.hasNext()){
            numbers.add(Scan.nextLine());
        }
        for(int i = 0; i &lt; numbers.size(); i++){ 
            System.out.println(numbers.get(i));
        }

        System.out.println("")

        Scan.close();
    }

}
</code></pre>
