public static bool operator <(Money Amount1, Money Amount2) { double c = Amount1.Course(Amount1, Amount2); bool compare2 = Amount1.Amount < (Amount2.Amount * c); return(compare2); }
// 4) declare overloading of operator + to add 2 objects of Money public static Money operator +(Money Amount1, Money Amount2) { double c = Amount1.Course(Amount1, Amount2); return(new Money(Amount1.Amount + Amount2.Amount * c, Amount1.CurrencyType)); }