3034ccom/lab01/frac.cpp
Fraction Fraction::sub(const Fraction& F) const {

	Fraction negFrac = F;
	negFrac.setNum(negFrac.getNum() * -1);

	Fraction localFrac = add(negFrac);

	return localFrac.reduce();
}
// Function sub
// 	Withou modifying the calling Fraction object,
//	subtracts two Fractions and returns the resulting
//	Fraction object. The subtraction is done by negative
//	addition.
Function sub
Withou modifying the calling Fraction object,
subtracts two Fractions and returns the resulting
Fraction object. The subtraction is done by negative
addition.
Function sub Withou modifying the calling Fraction object subtracts two Fractions and returns the resulting Fraction object . The subtraction is done by negative addition .
Fraction Fraction::sub(const Fraction& F) const {
	Fraction negFrac = F;
	negFrac.setNum(negFrac.getNum() * -1);
	Fraction localFrac = add(negFrac);
	return localFrac.reduce();
}
Fraction Fraction :: sub ( const Fraction & F ) const { Fraction negFrac = F ; negFrac . setNum ( negFrac . getNum ( ) * -1 ) ; Fraction localFrac = add ( negFrac ) ; return localFrac . reduce ( ) ; }
Function sub
Withou modifying the calling Fraction object,
subtracts two Fractions and returns the resulting
Fraction object.
Function sub Withou modifying the calling Fraction object subtracts two Fractions and returns the resulting Fraction object .