complex.h (Complex numbers header file)
#ifndef COMPLEX_H
#define COMPLEX_H
class Complex
{
public:
double r;
double i;
Complex(double, double);
Complex(double );
Complex();
Complex add(Complex&);
Complex operator+ (Complex&);
Complex operator- (Complex&);
Complex operator* (Complex&);
Complex operator/ (Complex&);
Complex operator/ (double);
Complex conj();
double norm();
void print();
};
#endif
CSE 230 material by Pawas Ranjan is licensed under a Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License. Source code for this website available at GitHub.