title: Functionally prepending an array element
body: <p>Is there a functional way to prepend an element to an array. Something like:</p>
  
  <pre><code>[1,2].prepend(3); // should return [3, 1, 2]
  </code></pre>
  
  <p>Kindly notice that a reference to the <strong>result</strong> array is returned. The reason is to be able to do more things with the same array.</p>
  
  <p>PS: I am asking about the MongoDB command-line interface.</p>
  
  <p>PPS: I am looking for the way that will (A) not switch the arrays order (B) IF POSSIBLE, not cause me to define any custom function.</p>