title: Add a file extension in R to multiple files
body: <p>I would like to add the ".txt" file extension to multiple files with no current extension. I can create a vector that contains the file paths using the code below, but I don't know how to add the ".txt" file extension: </p>
  
  <pre><code>startingDir &lt;-"/myDirectory"
  filez&lt;-list.files(startingDir)
  head(filez)
  [1] "/myDirectory/File1"
  [2] "/myDirectory/File2"
  [3] "/myDirectory/File3"
  </code></pre>