C++ Tutorials | L33: Friend Functions and Friend Classes in C++ | The Easy Concepts
#programming #cplusplusprogramming #cprogramming
In this tutorial, we have discussed the concepts of friend functions and friend classes along with their implementation details.
What is a Friend Function?
The friend function of a class is defined outside that class scope but it has the right to access all private and protected members of the class. Even though the prototypes for friend functions appear in the class definition, friends are not member functions.
Why do we need Friend function?
The special case when class’s private data needs to be accessed directly without using an object of that class.
Please watch the full video to learn the concepts in more detail.
Learn Computer Science Concepts in an Easy Way !!
http://www.theeasyconcepts.com/
Facebook - / theeasyconcepts
Twitter - / theeasyconcepts
You all can join Telegram group here - https://t.me/joinchat/QnirXRQcm_QnGEb...
You can join this Telegram channel where we will keep posting Programming and Placement related stuff - https://t.me/theeasyconcepts