You are viewing a single comment's thread. Return to all comments →
wow, not a very well crafted problem or working template. nothing wrong with learning and practicing binary search but this might confuse more than educate.
I agree the template code provide is likely to confuse people.
I've posted a commented version of the template here in the comments.