title: How do I calculate beforehand how much memory calloc would allocate?
body: <p>I basically have this piece of code.</p>
  
  <pre><code>char (* text)[1][80];
  text = calloc(2821522,80);
  </code></pre>
  
  <p>The way I calculated it, that calloc should have allocated 215.265045 megabytes of RAM, however, the program in the end exceeded that number and allocated nearly 700mb of ram.</p>
  
  <p>So it appears I cannot properly know how much memory that function will allocate.</p>
  
  <p>How does one calculate that propery?</p>