Finding the average of numbers in an array
<p>I have an array of <em>test grades</em> for each <em>student</em> in a class. As an example, for Adam <em>test1=90 test2=92 test3=93</em>, so the average would be <em>91.67</em>. I would then save this as <code>Array6</code>. Then using that array, I would take <em>30%</em> of that plus <em>70%</em> of the final (<code>array5</code>) to make new array <code>courseaverage</code>. </p>

<p>I have tried to implement this in my code below, but it doesn't work correctly. Could anyone please suggest the problem...</p>

<pre><code>public class Proj5 {
    public static void main (String[] args) {        
        String[] Array1 = {new String ("Adam"),new String ("Smith"),new String ("Jones"),new String ("Becky"),new String ("Taylor")};       
        Integer[] Array2 = {new Integer(90),new Integer(89),new Integer(86),new Integer(76),new Integer(95)};        
        Integer[] Array3 = {new Integer(92),new Integer(79),new Integer(85),new Integer(90),new Integer(87)};
        Integer[] Array4 = {new Integer(93),new Integer(80),new Integer(90),new Integer(87),new Integer(92)};
        Integer[] Array5 = {new Integer(90),new Integer(77),new Integer(86),new Integer(92),new Integer(89)};

        System.out.println("Name Test1 Test2 Test3 Final Average Grade");

        for (int column = 0; column&lt;Array1.length; column++){
            System.out.printf("%s ", Array1[column]);
            System.out.printf("%s   ", Array2[column]);
            System.out.printf("%s    ", Array3[column]);
            System.out.printf("%s    ", Array4[column]);
            System.out.printf("%s  ", Array5[column]);
            System.out.println(); //start new line of output
        }
    }
}
</code></pre>
