Can you solve the $20 riddle? ft SMBC Comics' Zach Weinersmith

The $20 riddle isn't logically correct, it assumes the converse of a conditional has the same truth value which it does not. If 'statement' is false you give me back $10, is not the same as saying if you give me $10 the statement is false. So he would give mathematician $10 and the statement would be true, or give mathematician nothing and then inevitably give $10 as the statement would be false. Am I wrong here?