package rocks.zipcode.io.quiz3.arrays; /** * @author leon on 09/12/2018. */ public class SquareArrayAnalyzer { public static Boolean compare(Integer[] input, Integer[] squaredValues) { int count = 0; for(int i = 0; i < input.length; i++){ Integer square = input[i]*input[i]; if(square.equals(squaredValues[i])){ count+=1; } } return count == squaredValues.length; } }