title: Determining sprintf buffer size - what's the standard?
body: <p>When converting an int like so:</p>
  
  <pre><code>char a[256];
  sprintf(a, "%d", 132);
  </code></pre>
  
  <p>what's the best way to determine how large <em>a</em> should be? I assume manually setting it is fine (as I've seen it used everywhere), but how large should it be? What's the largest int value possible on a 32 bit system, and is there some tricky way of determining that on the fly?</p>