Subset Sum Easy

If I try to give input array as for eg {1,0,2,3}. My program isn’t able to create 0 as a subset. I have taken the right approach to create the subsets, and I still don’t know why it’s failing for few cases. https://ide.codingblocks.com/s/336220

Your approach is not correct.
Check for this case:
1
4
1 1 2 -3
Your code gives output as “No”.

Refer to this approach.

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.