Examveda

What is the purpose of using friend functions in C++?

A. To create multiple instances of a class

B. To hide the implementation details of a class

C. To allow access to private and protected members of a class from outside the class

D. To define functions within a class

Answer: Option C


Join The Discussion

Related Questions on Classes and Objects in C plus plus