1.

If the left operand is pointed by *this pointer, what happens to other operands?(a) Other operands are passed as function return type(b) Other operands are passed to compiler implicitly(c) Other operands must be passed using another member function(d) Other operands are passed as function argumentsThis question was addressed to me by my college professor while I was bunking the class.Question is taken from Member Operator Function in chapter Member Functions & its Types of Object Oriented Programming

Answer»

The CORRECT choice is (d) Other operands are PASSED as FUNCTION arguments

The explanation is: The operands that are USED during overloading expect the left operand, can be passed as function arguments. Those are then referred in function definition with the names specified in the argument list.



Discussion

No Comment Found

Related InterviewSolutions