So I have a class with a > operator overloaded method. Its to use it with the priority_queue.
if I do:
bool operator>( const X& x0 )
{ return ( y > x0.y ); }
it gives me a compiling error, something like, no operator which takes a left hand object.
If I do
bool operator>( const X& x0, const X& x1 )
{ return ( x0.y > x1.y ); }
It says operator> has too many parameters.
Any suggestions?