title: A constant value is expected when initialize an array
body: <p>I developing an image processing software.</p>
  
  <pre><code>int size = 3;
  
  int[,] kernel = new int[size, size] {
          {1, 2, 1},
          {2, 4, 2},
          {1, 2, 1}
  };
  </code></pre>
  
  <p>When I compile my code, I have a compile error message "A constant value is expected" from <code>size</code> variable. I understand I can put 3 on my <code>kernel</code> array initialization or make my <code>size</code> constant. What I ask is the technical reason behind this error because this error don't make any sense for me.</p>