title: Calculating the address: pointer + non-negative number
body: <p>Pointers can only move in discrete steps. </p>
  
  <pre><code>int *p;
  p = malloc(sizeof(int)*8);
  </code></pre>
  
  <p>Therefore, formally *(p+2) is calculated as *(p+2*sizeof(int)). </p>
  
  <p>However If I actually code the above two, I get different results, which seems understandable. </p>
  
  <pre><code>*p = 123;
  *(p+2) = 456;
  printf("%d\n",*(p+2*(sizeof(int)))); \\0
  printf("%d\n",*(p+2)); \\456
  </code></pre>
  
  <p>The question is, is this calculation implicit, done by the compiler at compile time?</p>