Usage
map f
map! f
map(f)(a)
map!(f)(a)
Signature
map: (T T) % %
Parameter | Type | Description |
---|---|---|
f | T T | a map |
a | % | a finite linear structure |
Returns
map(f)(a) returns the new structure [f(x) for x in a], while map(f) returns the mapping [f(x) for x in a]. In both cases, map! does not make a copy of the structure a but modifies it in place.