group by length of array elements in object exercise add