Search
Write a program to calculate the sum of elements in each slice of an array. Use the each_slice method to iterate over the array in groups of 3.
each_slice
Display the results as follows: