I am not getting how to implement the code…please help me
Simple input problem
Hey shubham,
You have to calculate the cumulative sum of numbers as you are getting the input, and stop once you get the cumulative sum of numbers as negative.
pesudo code:
make an empty list sum=0 iterate till s>=0 read input s+= input append input to list outside loop print the list
I hope this clears your doubt.
Thanks
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.