Only one test case passing
@abhinavgoyal912 your code is not giving correct answer even for the sample input. Some changes need to be done.
Also, you need to report the final answer by taking mod.
Mam can u please tell me simple testcase where ths code isnβt working because iβm not able to figure out my mistake
@abhinavgoyal912 you can see the sample i/p o/p given in the question description. Dry run the code for it once.
mam i did that and its running perfectly fine for that and one of the test cases
@abhinavgoyal912
I think i was getting wrong answer after i made some changes, i apologise for the confusion.
Your logic is perfectly fine. The question needs you to print the ans % 10000003 so
![]()
Just change this one line, and it is now passing all the test cases.
1 Like
