Rain Water Harvesting

It is not printing the wrong result. Where is the problem in it?

@dsdishu99 i dont understand your logic it seems wrong . you can dry run the input to understand that it works incorrectly see this video by prateek bhaiya for correct approach


dont forget to hit like and mark resolved if cleared :smiley: