title: Higher dimensional array vs 1-D array efficiency in C++
body: <p>I'm curious about the efficiency of using a higher dimensional array vs a one dimensional array.  Do you lose anything when defining, and iterating through an array like this:</p>
  
  <pre><code>array[i][j][k];
  </code></pre>
  
  <p>or defining and iterating through an array like this:</p>
  
  <pre><code>array[k + j*jmax + i*imax];
  </code></pre>
  
  <p>My inclination is that there wouldn't be a difference, but I'm still learning about high efficiency programming (I've never had to care about this kind of thing before).</p>
  
  <p>Thanks!</p>