Which of the following is false for friend function?

Options
- Allows access to private or protected data in a class from outside the class
- both a and c
- Too many friend functions may hamper data security
- When a function needs to operate on private data in objects from two different classes, the function can be declared as a friend in any of the classes


CORRECT ANSWER : When a function needs to operate on private data in objects from two different classes, the function can be declared as a friend in any of the classes

Write your comments


Enter the code shown above:

(Note: If you cannot read the numbers in the above image, reload the page to generate a new one.)


Advertisement