I am trying to overload my operators its really just a class that holds arithmetic functions and a sequence of array variables.
But when i am overloading my (*) multiplication operator i get this error:
binary '*' : no global operator found which takes type 'statistician'
(or there is no acceptable conversion)
This happens when my code tries to do: s = 2*u;
in main.cpp
where s, and u are statistician classes.
statistician = my class
(statistician.h)
class statistician
{
... other functions & variables...
const statistician statistician::operator*(const statistician &other) const;
..... more overloads...
};
Any help would be awesome thanks!!