Subtract and Divide functions

Added subtraction and division functions with similar structures to the
addition function.