I started with the fact that he could not have ten dimes or more, therefore any number greater than 5 had to be wrong.

Then I calculated B and it was correct.