Adding subtraction logic problem