Question: 1. Write a class ComplexNumber (declaration and implementation) that has the following private data members: a) an int m real b) an int m imaginary

 1. Write a class ComplexNumber (declaration and implementation) that has the

1. Write a class ComplexNumber (declaration and implementation) that has the following private data members: a) an int m real b) an int m imaginary and the following public member functions: a) A Parametrized ctor that takes 2 int parameters to initialize m_real and m_imaginary to specific values. You are required to use Initializer-list syntax to perform this. You are required to use Initializer-list syntax to perform this. An assignment operator that assigns from another ComplexNumber object to the calling object. An operator+ function that sums 2 complex numbers (resulting ComplexNumber is the sum of real parts and the sum of imaginary parts). c) d) and also uses: e) An insertion operator

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!