title: How to remove all element from array except the first one in javascript
body: <p>I want to remove all element from array except the element of array at 0th index</p>
  
  <pre><code>["a", "b", "c", "d", "e", "f"]
  </code></pre>
  
  <p>Output should be <code>a</code></p>