#include using std::cout; using std::cin; #include "Complessi.h" int main() { Complessi x; Complessi y( 4.3, 8.2 ); Complessi z( 3.3, 1.1 ); Complessi k; cout << "Dammi un numero complesso nella forma: " << "a + bi\n? "; cin >> k; cout << "x: " << x << "\ny: " << y << "\nz: " << z << "\nk: " << k << '\n'; x = y + z; cout << "\nx = y + z:\n" << x << " = " << y << " + " << z << '\n'; x = y - z; cout << "\nx = y - z:\n" << x << " = " << y << " - " << z << '\n'; x = y * z; cout << "\nx = y * z:\n" << x << " = " << y << " * " << z << "\n\n"; if ( x != k ) cout << x << " != " << k << '\n'; cout << '\n'; x = k; if ( x == k ) cout << x << " == " << k << '\n'; return 0; } // end main