|
FoldList
FoldList[f, x, a, b, ... ] ergibt x, f[x, a], f[f[x, a], b], ... .
Beispiel: FoldList[f, x, a, b, c ] .
FoldList[Plus, 0, liste] erzeugt kumulative Summen der Elemente in liste.
Beispiel: FoldList[Plus, 0, a, b, c ] .
Mit einer Liste der Länge erzeugt FoldList eine Liste der Länge .
Der Kopf von liste in FoldList[f, x, liste] muß nicht List sein.
Siehe Das Mathematica Buch: 2.2.2.
Siehe auch: Fold, NestList, ComposeList, Partition, MapIndexed.
Further Examples
|