Do i have to take inputs one by one or all inputs at once

question : simple input
do i have to take inputs one by one or all inputs at once

Hi Nipun

You have to run an infinite loop in this question and keep taking inputs until the cummulative sum of all the input becomes negative.
The reason for taking infinite loop for this question is that we don’t know when the cummulative sum will become less than 0. Hence, we keep on taking inputs.

Hi Nipun
As you are not responding to this thread, I am marking your doubt as Resolved for now. Re-open it if required.

Please mark your doubts as resolved in your course’s “ Ask Doubt ” section, when your doubt is resolved.