You are viewing a single comment's thread. Return to all comments →
I agree. That piece of code should be something like:
if (k % 2 == 0 && ctnts[k/2] > 0) { cnt += 1; }
The following case (and other similar cases) wouldn't work otherwise:
4 8 1 7 2 6
Seems like cookies are disabled on this browser, please enable them to open this website
Non-Divisible Subset
You are viewing a single comment's thread. Return to all comments →
I agree. That piece of code should be something like:
The following case (and other similar cases) wouldn't work otherwise: