Charlie, your proposed solutions don't satisfy the second condition of the problem. The line "c = tot - 12" stands out.
blackjack
flooble's webmaster puzzle