title: reduceRight in Protractor
body: <p>There are two ways to reduce regular javascript arrays: </p>
  
  <ul>
  <li><a href="http://www.ecma-international.org/ecma-262/6.0/#sec-array.prototype.reduce" rel="nofollow"><code>reduce()</code></a> (from-left-to-right) </li>
  <li><a href="http://www.ecma-international.org/ecma-262/6.0/#sec-array.prototype.reduceRight" rel="nofollow"><code>reduceRight()</code></a> (from-right-to-left)</li>
  </ul>
  
  <p>In Protractor, there is <a href="http://www.protractortest.org/#/api?view=ElementArrayFinder.prototype.reduce" rel="nofollow"><code>reduce()</code></a> which would work from the left element to the very right: </p>
  
  <blockquote>
    <p>Apply a reduce function against an accumulator and every element found using the locator (from left-to-right). </p>
  </blockquote>
  
  <p>Is there <code>reduceRight()</code> method in Protractor and, if not, would it be possible to implement it based on <code>reduce()</code>? </p>