simple C++ inheritance
<p>With the following code I want accomplish two different values for intA, but I get:</p>

<p>clsA a=1?  1
clsB a=2?  1</p>

<pre><code>//Code
#include &lt;iostream&gt;
using namespace std;
class clsA {
    static const int intA = 1; 
public:
    virtual int get_a() { return intA; }
};
class clsB: public clsA { 
    static const int intA = 2;   
}; 
int main() { 
    clsA a; clsB b;
    cout &lt;&lt; "clsA intA =  " &lt;&lt; a.get_a() &lt;&lt; endl;
    cout &lt;&lt; "clsB intA =  " &lt;&lt; b.get_a() &lt;&lt; endl;
}
</code></pre>

<p>How can I get intA=1 for object a and intA=2 for object b?
Thanks for the reaction,
André</p>
