To Create A Pointer To A Private Data Member Of A Class Outside #262
To create a pointer to a private data member of a class, outside the class, which among the following is correct?
This multiple choice question (MCQ) is related to the book/course
gs gs111 OOP Object Oriented Programming Java.
It can also be found in
gs gs111 Class Members & Types - Object Oriented Programming MCQ: Data Members - Quiz No.1.
To create a pointer to a private data member of a class, outside the class, which among the following is correct?
Return the address of the private data member using a member function
Access the private member using a pointer outside class
Declare the member as pointer inside the class
Not possible to create pointer to a private member