• Tutorials
  • Courses
  • Tracks

C++ | this pointer | Question 2

Last Updated :
Discuss
Comments

What is the use of this pointer?

When local variable’s name is same as member’s name, we can access member using this pointer.

To return reference to the calling object

Can be used for chained function calls on an object

All of the above

Share your thoughts in the comments