how to access private class list?
<p>i dont know this solution...</p>

<p>for example, my code is,</p>

<pre><code>class Bank
{
 private :
  list &lt; Client*&gt; clientList;

}

class Client
{
private :
 list&lt; Account*&gt; accountList;

}

class account
{
private 
 list&lt; string&gt; statement;

}
</code></pre>

<p>oh, i want to access statement in bank class! and i think how to access its...</p>

<p>1) making <code>list&lt; Account*&gt; getAccountList()</code> method in Client class and <code>list&lt;string&gt; getStatement()</code> method in Account.</p>

<p>but why list is private? umm, may as well public?</p>

<p>2) making list access method(umm, for example, pop and push?) in All Class..</p>

<p>i got 2. but it's terrible. I have a lot to do, and repeated similar function...</p>

<p>what is best way? it is way i never know?</p>
