Kadane's Algorithm

I am using kadane’s Algorithm for subArray sum.
but it is returning one error.
Please tell me a test case of that problem.

hi @roshani1997abr_911f71e73100e81b send the code on online ide

Please check and let me know
what I am missing?

hi @roshani1997abr_911f71e73100e81b, updated

for test case, I have to write a loop for test case.

yes @roshani1997abr_911f71e73100e81b

after submitting a solution why code are gone.

Can you please explain a input

how it is working?

2
4
1 2 3 4
3
-10 5 10

hi its running algo 2 times as first line is 2 (no of test cases)

okay, Got it.
Thank you

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.