By using this site, you agree to our Privacy Policy and our Terms of Use. Close
TheSource said:

hmm...don't know what right-hand side is either...

Oh, sorry then. I assumed you didn't know what the mnemonic meant.

Rhs there is just the name of the variable. You're overloading operators there, so e.g. when you have a+b the operator+(...) "method" will be called on "object" a with parameter b. Since b is on the right-hand side of + in the a+b expression, it's one possible, albeit common practice to call the parameter to operator+(...) by the name rhs. But you might as well call it x, or something else.

I hope that was more helpful.



Reality has a Nintendo bias.