|
map
|
The map Function applies the specified function {proc}
to each value in the {pair}. The map function returns a
List containing the result of the each mapping. The function
{proc} must be a function that requires a single argument.
The map function is a non-destructive function useful when you want to apply a native or user-defined function to each element in a Pair. The map function is a shortcut to updating elements in a Pair or List without having to set up a loop and reference each element individually. For instance, the map function, with arguments of {proc} and {list}, is equivalent to the following generic loop code:
(loop for i from 0 until (length list) do (proc list[i]))
(map proc pair) A new Pair object containing values that have the values updated by
applying the map function to each value.
Here are a number of links to Lambda coding examples which contain this instruction in various use cases.
Here are the links to the data types of the function arguments. Here are also a number of links to functions having arguments with any of these data types.
You can always talk with the AIS at aiserver.sourceforge.net.
Name
Description
AIS Types proc A function requiring a single argument. Function pair A Pair containing the argument values for the function {proc} Pair
Returns:
Examples
Argument Types
Structure
Dictionary
NumMatrix
Directory
Vector
Matrix
Pair
List
ShortVector
FltVector
IntVector
NumVector
How do I contact the AIS team?