title: Is it legal to overrun one element of a struct to view another?
body: <p>Given the following contrived example code:</p>
  
  <pre><code>struct abc
  {
      int x[5];
      int y[5];
  };
  
  void main()
  {
      struct abc test;
      test.y[0] = 10;
      printf("%n", test.x[5]);
  }
  </code></pre>
  
  <p>The output of the program is 10.</p>
  
  <p>While not the best programming practice, this does work. However, is this an artifact of the compiler and platform, or is this legal code? (i.e. defined by the C standard?)</p>
  
  <p>Even if the result is not guaranteed to be 10, is there ever an instance where this would be "illegal" (i.e. writing to memory I do not "own")?</p>