title: How do you pass a string as an argument to Node from the command-line?
body: <p>I'm new to Node and I'm trying to write a command-line tool in Node that would allow you to pass a string in as an argument.</p>
  
  <p>I saw that Node seems to break each word passed in as an array when using <code>process.argv</code>. I was wondering if the best way to grab the string is to loop through the array to construct the string or if there was a different option?</p>
  
  <p>So let's say I have a simple program that takes a string and simply console.logs it out. It would look something like this.</p>
  
  <pre><code>&gt; node index.js This is a sentence.
  &gt; This is a sentence.
  </code></pre>