Google News
logo
CPP - Quiz(MCQ)
How the objects are self-referenced in a member function of that class.
A)
By passing self as a parameter in the member function
B)
Using * with the name of that object
C)
Using a special keyword object
D)
Using this pointer

Correct Answer :   Using this pointer


Explanation : In Classes objects are self-referenced using this pointer inside the member functions. for example this->value to access the data member value of that object.

Advertisement