Friends and nested classes <p>Ok I'm totally frazzled on this. Code is begin to swim around the screen...must sleep.</p> <p>So! Ok, troubled by nested classes and friends.</p> <p>here is the pseudo-code</p> <pre><code> class A{ public: //constructor // member functions private: class B{ //private int a(); }; class C{ //private int b(); }; }; </code></pre> <p>So once an object of type A has been created, I would like it to access a() and b(). I know that I have to use a friend function for this. So where should I put friend class A. Is that the right expression?.</p>