// main.cpp
#include <iostream>
#include <cmath>
#include "Complex.cpp"
#include "Fraction.cpp"
#include "FracComplex.cpp"

using namespace std;


int main() {
	Complex c1;               cout << "c1              = " << c1  << endl;
	Complex c2(1, 1);         cout << "c2(1, 1)        = " << c2  << endl;
	Complex c3(-1, 1);        cout << "c3(-1, 1)       = " << c3  << endl;
	Complex c4(1, -1);        cout << "c4(1, -1)       = " << c4  << endl;
	Complex c5(-1, 2);        cout << "c5(-1, 2)       = " << c5  << endl;
	Complex c6(5, -2);        cout << "c6(5, -2)       = " << c6  << endl;
	Complex c7(-12, 0);       cout << "c7(-12, 0)      = " << c7  << endl;
	Complex c8(0, -21);       cout << "c8(0, -21)      = " << c8  << endl;
	Complex c9(0, -1);        cout << "c9(0, -1)       = " << c9  << endl;
	Complex c10(0, 2);        cout << "c10(0, 2)       = " << c10 << endl;
	Complex c11(-1);          cout << "c11(-1)         = " << c11 << endl;
	Complex c12(2);           cout << "c12(2)          = " << c12 << endl;

	Complex c13 = c6;         cout << "c13 = c6        = " << c13 << endl;
	Complex c14; c14 = c6;    cout << "c14 = c6        = " << c14 << endl;
	Complex c15 = -3 + 2*i;   cout << "c15 = -3 + 2*i  = " << c15 << endl;
	Complex c16 = -21*i;      cout << "c16 = -21*i     = " << c16 << endl;
	Complex c17 = -i + 11;    cout << "c17 = -i + 11   = " << c17 << endl;
	Complex c18 = i * 3 - 4;  cout << "c18 = i * 3 - 4 = " << c18 << endl;

	Fraction f1(0, 7);              cout << "f1(0, 7);             = " << f1  << endl;
	Fraction f2(3, 1);              cout << "f2(3, 1);             = " << f2  << endl;
	Fraction f3(3, -1);             cout << "f3(3, -1);            = " << f3  << endl;
	Fraction f4(1, -1);             cout << "f4(1, -1);            = " << f4  << endl;
	Fraction f5(-1, 2);             cout << "f5(-1, 2);            = " << f5  << endl;
	Fraction f6(1, -2);             cout << "f6(1, -2);            = " << f6  << endl;
	Fraction f7 = 0;                cout << "f7 = 0;               = " << f7  << endl;
	Fraction f8 = Fraction(-1)/5;   cout << "f8 = Fraction(-1)/5;  = " << f8  << endl;
	Fraction f9 = -1/Fraction(5);   cout << "f9 = -1/Fraction(5);  = " << f9  << endl;
	Fraction f10 = (Fraction)-1/5;  cout << "f10 = (Fraction)-1/5; = " << f10 << endl;
	Fraction f11 = -1/5;            cout << "f11 = -1/5;           = " << f11 << endl;  // !!!
	Fraction f12(5);                cout << "f12(5);               = " << f12 << endl;
	Fraction f13 = -1/f12;          cout << "f13 = -1/f12;         = " << f13 << endl;
	Fraction f14 = f12/f13;         cout << "f14 = f12/f13;        = " << f14 << endl;

	FracComplex fc1(Fraction(1, 5), Fraction(-3, 8));  cout << "fc1(Fraction(1, 5), Fraction(-3, 8)) = " << fc1 << endl;
	FracComplex fc2(Fraction(15), Fraction(-3));       cout << "fc2(Fraction(15), Fraction(-3))      = " << fc2 << endl;
	FracComplex fc3(15, -3);                           cout << "fc3(15, -3)                          = " << fc3 << endl;

	return 0;
}
