Dsa series



This is my solution of problem “CARVAN” .it gives correct answer of the test on compiler but when I submit it it shows wrong answer?

Whats wrong in this code??

Firstly, you’ve given a link to a submission of an ongoing contest. This isn’t visible to anyone other than you during the duration of the contest. Secondly, please elaborate your doubt. Simply asking what is wrong with your solution isn’t helpful. Try to give atleast a short explanation of what your code does, the exact problem you’re facing. You can find how to ask question in a better way in other discussion posts.

Happy coding