title: Creating a class that squares and sums an array?
body: <p>I'm trying to write a class method that squares, then sums an array but I've no clue how to advance from here. I also don't know if I should split the method to square it and then another to sum it or if i can actually combine them into this one. Here's what I've come up with so far...though its not much.</p>
  
  <pre><code>public int sqSum(){
      for(int i=0; i&lt;array.length; i++)
  
          int sqSum = array[i] * array[i];
  
      return sqSum;
  }   
  </code></pre>