0
what is the use of friend function??
2 Respostas
+ 6
A friend function can access private and protected members of a class. You can also use a static function rather than a friend one for the same purpose, there is not much difference (except that a static function belongs to the class).
+ 1
actually friend function are the functions which are not declared in a class but it can access by the class .