Haskell Language Mapping (`map`) and Reducing (`fold`) a Vector


Example

Vectors can be map'd and fold'd,filter'd andzip`'d:

Prelude Data.Vector> Data.Vector.map (^2) y
fromList [0,1,4,9,16,25,36,49,64,81,100,121] :: Data.Vector.Vector

Reduce to a single value:

Prelude Data.Vector> Data.Vector.foldl (+) 0 y
66