Example #1
0
Mixed Mixed::operator /(Mixed &p){
		p.ToFraction();
		Mixed tmp(0, b*p.c,c*p.b);
		tmp.Simplify();
		return tmp;
}
Example #2
0
Mixed Mixed::operator +(Mixed &p){
		p.ToFraction();
		Mixed tmp(0, (b*p.c) + (p.b*c),c*p.c);
		tmp.Simplify();
		return tmp;
}
Example #3
0
Mixed Mixed::operator -(Mixed &p){
		p.ToFraction();
		Mixed tmp(0, (b*p.c) - (p.b*c),c*p.c);
		tmp.Simplify();
}
Example #4
0
bool Mixed::operator !=(Mixed &p){
		p.ToFraction();
		int y = p.get_y(), z = p.get_z();
		return ((((b*z) != (y*c)))?1:0);
}