0

write a c++ programme which demonstrate the use of friend class?

using friends class

15th Nov 2016, 5:52 AM
Noor Haider Okz
Noor Haider Okz - avatar
1 Answer
0
A friend class is a class that has access to members or methods from another class that it would normally not have access to. The basic look is like so: class A { }; class B { friend class A; // Class A is a friend of B, giving A access to B's private members/methods };
18th Nov 2016, 1:16 AM
scott johnson
scott johnson - avatar