Content deleted Content added
Undid revision 1228084066 by 201.175.202.119 (talk) |
third person |
||
Line 7:
The concept of a map is not limited to lists: it works for sequential [[Container (abstract data type)|containers]], tree-like containers, or even abstract containers such as [[futures and promises]].
== Examples: mapping a list ==
Suppose
<syntaxhighlight lang="haskell">
Line 15:
</syntaxhighlight>
Afterwards
<syntaxhighlight lang="haskell">
Line 24:
=== Visual example ===
Below,
[[File:Mapping-steps-loillibe-new.gif|alt=applying map function processing steps|none|thumb|480x480px|View of processing steps when applying map function on a list]]
Line 36:
</syntaxhighlight>
== Generalization ==
{{see also|Functor|Category theory}}
|