Divisible subarray

https://ide.codingblocks.com/s/64037
showing wrong answer in 2nd test case

hey anshuman, Change your size of array to 10000005, and you have only added n to sum when it is negative only once , what is value is still negative after adding n so add n till the value of sum is positive, also the data type of number in line 32 should be long long int