Eh, are you talking about foldLeft and foldRight in Scala? those are not
from Hadoop or Spark.
They are common functions in functional languages. They 'fold' a value into
a new value by apply a function to the starting value and every element of
a collection.
Because the op may be non-commutative, doing this left to right or right to
left is different, hence two functions.

On Fri, Jan 21, 2022 at 6:59 AM Theodore J Griesenbrock <t...@ibm.com>
wrote:

> I discovered several instances of discussion on leftFold and rightFold in
> a variety of forums, but I can not find anything related to RDD in the
> official documentation:
>
>
> https://spark.apache.org/docs/latest/api/scala/org/apache/spark/rdd/RDD.html
>
> It appears to be non-related to Spark, and probably something
> Hadoop-related.  Can you please be more specific on how leftFold and
> rightFold is imported and the language you are using to implement Spark?
>
> Thanks!
>
> -T.J.
>
>
> *T.J. Griesenbrock*
> Technical Release Manager
> Watson Health
> He/Him/His
>
> +1 (602) 377-7673 (Text only)
> t...@ibm.com
>
> IBM
>
>
>
> ----- Original message -----
> From: "Sherd Fox" <sherd...@gmail.com>
> To: user@spark.apache.org
> Cc:
> Subject: [EXTERNAL] questions on these functions
> Date: Fri, Jan 21, 2022 04:26
>
> Hello sparkers,
>
> What were the differences for leftFold, rightFold and the fold in RDD
> functions?
>
> I am not very clear about the usage of them.
>
> Thanks.
>
>
>
>
> --------------------------------------------------------------------- To
> unsubscribe e-mail: user-unsubscr...@spark.apache.org

Reply via email to