Here you can find the source of SumSquared(Object in)
public static final int SumSquared(Object in)
//package com.java2s; //License from project: Open Source License public class Main { public static final int SumSquared(Object in) { if (in == null) return 0; if (in instanceof int[]) { int[] inn = (int[]) in; int out = 0; for (int i = 0, s = inn.length; i < s; i++) out += inn[i] * inn[i];/*from w w w. j a va2 s.c om*/ return out; } else { int out = 0; for (int i = 0, s = ((Object[]) in).length; i < s; i++) out += SumSquared(((Object[]) in)[i]); return out; } } }