title: How to store an Array[String] to an output file
body: <p>I'm having an Array[String] called samparr with some values in it, I want it to get stored as an output file.</p>
  
  <pre><code>var samparr: Array[String] = new Array[String](4)
  samparr +:= print1 + "  BEST_MATCH  " + print2
  </code></pre>
  
  <p>just like,</p>
  
  <pre><code>val output = samparr.saveAsTextFile(outputpath)
  </code></pre>
  
  <p>but isn't a RDD its an Array[String]</p>