title: Why does redefining a static global variable give a compile-time error when redefining a global variable does not?
body: <p>Compiling code 1 gives an error '<code>i redefined</code>', but code 2 shows no similar error.  Why is it so?</p>
  
  <h3>Code 1</h3>
  
  <pre><code>static int i;        //Declaring the variable i.
  static int i=25;     //Initializing the variable.
  static int i;        //Again declaring the variable i.
  int main(){       
      return 0;
  }
  </code></pre>
  
  <h3>Code 2</h3>
  
  <pre><code>int i;        //Declaring the variable i.
  int i=25;     //Initializing the variable.
  int i;        //Again declaring the variable i.
  int main(){       
      return 0;
  }
  </code></pre>