title: Thrown exception: Access violation writing location 0x00000000
body: <p>I keep getting the following error for the following code segment. I don't know what it means. Can someone tell me why I keep getting it?</p>
  
  <blockquote>
    <p>Unhandled exception at 0x5A0DB49C (msvcr110d.dll) in ConsoleApplication8.exe: 0xC0000005: Access violation writing location 0x00000000.</p>
  </blockquote>
  
  <pre><code>#include &lt;stdio.h&gt;
  #include &lt;string.h&gt;
  
  int main ( void )
  {
      char str[]="asd asd 3, 5; 12, 525; 123, 45235;";
      int a[100]={0};
      int b[100]={0};
      int i=0;
      sscanf (str, "asd asd %d, %d; %d, %d; %d, %d;", a[0], b[0], a[1], b[1], a[2], b[2]);
  
      for (i=0; i&lt;3; i++){
  
          printf ("%d %d\n", a[i], b[i]);
  
      }
      return 0;
  
  }
  </code></pre>