fix: incorrect constructor delegation

This commit is contained in:
Tajmeet Singh
2020-06-23 14:53:09 +01:00
parent 8969047d3f
commit 626ab31095

View File

@@ -36,7 +36,10 @@ class Complex {
* Complex Constructor which initialises the complex number with no * Complex Constructor which initialises the complex number with no
* arguments. * arguments.
*/ */
Complex() { Complex(0.0, 0.0); } Complex() {
this->re = 0.0;
this.im = 0.0;
}
/** /**
* Member function (getter) to access the class' re value. * Member function (getter) to access the class' re value.