Related to the final code in this video

I think the ans will be wrong if the maximum subarray is the total array itself…

@gauravrai628 hey gaurav there is issue in the code you can refer to this line of the code maximum subarray sum. if you are talking about like this senario
5
1 2 3 4 5
this code will give output as 15

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.

Thanks , answer was good