Divisible subarrays

sir, the size of the array is 5 which was {1,3,2,6,4}
so why is the cummulative sum array%5 size is 6 {0,1,4,1,2,1}?
why its size become 6 if we have already 5 element?!

hello @mzk1994

size of cummulative sum array will still remain n (size of original array)

becuase we are always doing cummulative sum %n which will ensure that
obtained values always remain in range [0…n-1]