Help ramu test case fails

https://ide.codingblocks.com/#/s/30579 this is the link to code idk why my test case is failing though my output is coming correct.

Problem Link please…

This has been very well explained by Prateek sir in this video…

Ya i saw this and did what he said. The compiler is showing the right answer but the test case is failing

Please send problem link…

even i am facing the same problem
code link-
https://ide.codingblocks.com/s/45781
problem link-
https://hack.codingblocks.com/contests/c/537/104

Hey Aditi, your code is not handling some corner cases. For eg.
input:
5 5 5 1
1 1
0
0

your output : 1
but correct output is 0.

I think you got it wrong. My output is zero only.

and earlier it was showing test case failed, and now it’s showing no output

Hey Aditi, initialize ans=0,cor=0,coc=0;variables inside while(t--) loop as initially their value should be zero for every test case.

Yes, thank you so much Sanjeet. It passed all the test cases now.

Great :+1: Keep coding and raising doubts :slight_smile: