title: Defining static members in C++
body: <p>I am trying to define a public static variable like this :</p>
  
  <pre><code>public :
           static int j=0;        //or any other value too
  </code></pre>
  
  <p>I am getting a compilation error on this very line : ISO C++ forbids in-class initialization of non-const static member `j'.</p>
  
  <ol>
  <li><p>Why is it not allowed in C++ ?</p></li>
  <li><p>Why are const members allowed to be initialized ?</p></li>
  <li><p>Does this mean static variables in C++ are not initialized with 0 as in C?</p></li>
  </ol>
  
  <p>Thanks !</p>