Test cases are not passing

please check what is wrong with my code why test cases are not passing

@Gaurav_dev
there is mistake in line no 42, it should be cout<<β€œNo”<<endl; β€œ<<” not β€œ<”
Also at the end at end of iszero() function write return false;

please check my code again on the provided link …it is return false at the end of iszero function and it is cout<<β€œNo”<<endl; which is perfect according to the problem statement

@Gaurav_dev
Your logic is not correct. Why are you just checking only two index i,j for sum to be zero?
Consider this testcase
1
4
-1 -5 4 2
Ans should be β€œYes” here because sum of all element will result in zero { (-1) + (-5) + 4 + 2 = 0 } . But your code is giving β€œNo”

can you provide the right code by making changes in my code

@Gaurav_dev
I have modified your code , please check here https://ide.codingblocks.com/s/238244

@Gaurav_dev
as i can see you got 100 points for this question. Please mark this doubt as resolved.

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.