I have a two operator with the same operator*.One of the get two class parameter and the other gets 2 class parameter and one integer value.Also I want to use assignment operator.I got an error.All of them implemented in header file.Here is codes.
A& operator*(A& a1, A& a2)
A& operator*(A& a1, A& a2,int x)
I got too many parameters for this operator function error for the above.
operator=must be member functon for that:
A& operator=(A& a1, A& a2);
How can I fix this problems.
operator *
take 3 parameters? What is it supposed to do with so many parameters? – AnT