title: How to use R's sprintf to create fixed width strings with fill whitespace at the END?
body: <p>I have vector of strings and want to create a fixed with string out of that. Shorter strings should be filled up with white spaces. E.g.:</p>
  
  <pre><code>c("fjdlksa01dada","rau","sjklf")
  sprintf("%8s")
  # returns
  [1] "fjdlksa01dada" "     rau"      "   sjklf"
  </code></pre>
  
  <p>But how can I get the additional whitespace at the END of the string?</p>
  
  <p>Note that I heard of write.fwf from the <code>gdata</code> package which is really nice but doesn't help much in this case, because I need to write a very specific non-standard format for an outdated old program. </p>