+ 2
Is there any way to use data members of private class in another class functions?
3 Respostas
+ 1
No. Make them "protected" to be able to inherit in subclass.
+ 1
Yes we can use friend function
0
Well i'd prefer to inherit than to make changes to both classes by adding "friend function".