Playing with reduceLeft, reduceRight, foldLeft, foldRight API in Scala

posted by anishaanisha 617 days, 2 hours, 37 minutes ago
Wednesday, August 08, 2012 9:37:19 PM GMT

In our previous post we saw in detail about the foreach. map, flatMap and collect methods in the Iterable trait. In this post we will look into detail about reduceLeft, reduceRight, foldLeft, foldRight methods of the Iterable trait. These methods are almost similar in the way the operate on the collection so it should be easier to study them together. reduceLeft/reduceRight: The scala doc declares this method as:reduceLeftB >: A ⇒ B): B which means that this method accepts a function whic...

category: Java EE | clicked: 10 | | source: www.javabeat.net | show counter code
tags: foldLeft, foldRight, reduceLeft, reduceRight, Scala

To post comments using your Facebook,Twitter, Gmail etc credentials in the Discus comments section. Or use your Javapins credentials at the end of the page.
To post your comment as a Javapins user please login or signup to Javapins database.