Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include<iostream>
- #include "Fraction.h"
- using namespace std;
- int main ()
- {
- Fraction f1(1,2);
- Fraction f2(1, 2);
- Fraction f3 (3, 5);
- if (f1.equal(f2))
- cout << "\nFraction f1 equals f2 : ";
- else
- cout << "\nFraction f1 NOT equal f2 : ";
- cout << "\n\n";
- if (f1.equal(f3))
- cout << "\nFraction f1 equals f3: ";
- else
- cout << "\nFraction f1 NOT equal f3: ";
- cout << "\n\n";
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement