title: num2str sets a constant width for integer formatting
body: <p>I am using <code>num2str</code> to print an array of integers. My problem is that the format <code>%d,</code> (notice no flag or field width) doesn't yield a comma-separated list of values as I would expect. </p>
  
  <p>Instead, it seems that all elements are forced to the same width by introducing spaces. I would like to get rid of these spaces. For example:</p>
  
  <pre><code>&gt;&gt; num2str(randi(10,1,10),'%d,')
  7, 8,10,10, 2, 2, 7, 1, 6, 6,
  
  &gt;&gt; num2str(randi(10,1,10),'%d,')
  9,5,4,7,8,6,4,2,6,3,
  </code></pre>
  
  <p>In the first example, you can see that all elements have a width of 2 -- this is the largest width among all elements, but I would prefer the output list to be compact: <code>7,8,10,10,2,2,7,1,6,6,</code>. In the second example, the largest width is 1, and there are no spaces introduced. I don't understand why Matlab would force all elements to have equal field length.</p>