title: Swift formatting a string to a certain length
body: <p>I have a series of string that I need to print on 1 line.</p>
  
  <pre><code>var qty: Int = 1
  var name: "Book"
  var price: 13.50
  </code></pre>
  
  <p>I need each to have blank space appended to them so they are a certain length or have characters removed if they are too long. For the qty id like it to be a length of 3, name 30 and price 8</p>
  
  <p>Format should be</p>
  
  <pre><code>1   Book                             13.50
  </code></pre>