subtract refactured