title: Array initialization: memory usage
body: <h3>CONTEXT</h3>
  <p>I am studying the array definitions. My question sticks with char array for simplicity.
  Debian 64bit.</p>
  <h3>PROBLEM</h3>
  <p>When I declare those arrays, here is my understanding :</p>
  <pre><code>char d[10]; 
  </code></pre>
  <p>=&gt; I get 10 * 1 byte memory usage.</p>
  <pre><code>char d[] = &quot;hellofooo&quot;; 
  </code></pre>
  <p>=&gt; 9 bytes + '\0' =&gt; 10 * 1 byte memory usage</p>
  <pre><code>char * d = &quot;hellofooo&quot;;
  </code></pre>
  <p>=&gt; 9 bytes + '\0' somewhere in the memory + 8 bytes for the pointer (64 bits)</p>
  <p>So, if my understanding is good, we should always prefer the second solution [] to minimise the memory consumption when we do not know upfront the size of the char?</p>
  <p>There is no need for pointers in my code. Just trying to find the most ram efficient solution.</p>