FoldPair[f,y0,list]
gives the last element of FoldPairList[f,y0,list].
FoldPair[f,y0,list,g]
gives the last element of FoldPairList[f,y0,list,g].


FoldPair
FoldPair[f,y0,list]
gives the last element of FoldPairList[f,y0,list].
FoldPair[f,y0,list,g]
gives the last element of FoldPairList[f,y0,list,g].
Examples
open all close allApplications (2)
Properties & Relations (2)
FoldPair returns the last element of the list returned by FoldPairList:
FoldPair does not return by default the remainder of the process:
Use Last in the fourth argument to get the remainder:
Use Identity in the fourth argument to get both:
Possible Issues (2)
The function in the first argument of FoldPair must return a pair of expressions:

FoldPairList[f,y0,{}] returns an empty list, with no last element:
Therefore FoldPair[f,y0,{}] stays unevaluated:
Related Guides
History
Text
Wolfram Research (2015), FoldPair, Wolfram Language function, https://reference.wolfram.com/language/ref/FoldPair.html.
CMS
Wolfram Language. 2015. "FoldPair." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/FoldPair.html.
APA
Wolfram Language. (2015). FoldPair. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/FoldPair.html
BibTeX
@misc{reference.wolfram_2025_foldpair, author="Wolfram Research", title="{FoldPair}", year="2015", howpublished="\url{https://reference.wolfram.com/language/ref/FoldPair.html}", note=[Accessed: 15-August-2025]}
BibLaTeX
@online{reference.wolfram_2025_foldpair, organization={Wolfram Research}, title={FoldPair}, year={2015}, url={https://reference.wolfram.com/language/ref/FoldPair.html}, note=[Accessed: 15-August-2025]}