Can we find the sequence of elements in array using kadane's algo

can we find the array sequence which is providing the max subarray sum rather than finding the maximum subarray sum.
i tried but not able to find the array sequence.

hello @Rajan_42
to print subarray having max sum you can make two extra variable s and e (they store starting and ending index of subarray respectively)

refer this code-> https://ide.codingblocks.com/s/269959