Definition of a Friend Function
What is meant by friend function?
Answers
Answered by
2
A function F is defined in a class A, is declared as friend function in another class B.
F has access also to the private and protected data in class B. If F is not declared as a friend function, then F has access only to the public data in class B.
F has access also to the private and protected data in class B. If F is not declared as a friend function, then F has access only to the public data in class B.
Similar questions
Math,
8 months ago
Accountancy,
1 year ago
Biology,
1 year ago
English,
1 year ago
History,
1 year ago