Friend functions in C++
In this tutorial you will learn:
1. What are friend functions?
2. Why to use friend functions?
3. How to use friend function in a program?
4. Basic C++ syntax
What are friend functions?
Friend functions are those functions which can access the private as well as the protected data members of the classes. We can make a function friend of two classes so that this function can use the private and protected member of those classes to produce a specific result. We can also make two classes friends of each other.
Why use friend functions?
We use friend