Q. What is the purpose of the ‘this’ keyword?

A
To refer to the current object
B
To create a new object
C
To declare a new class
D
To define a static method
Solution:

The this keyword refers to the current instance of the class, used to access its fields or methods.

Entri Contact Image

Get Expert Advice for Free: Register for Your Free Consultation Now!