MapIndexed
f applied to each part together with its position path, a list.
✓ checked against that system · ! checked, with disagreements (hover a chip)Wolfram Language
MapIndexed✓MapIndexed(f, list){f(a1, {1}), f(a2, {2}), …} — the index is a LIST, not a bare integerMapIndexed(f, list, levelspec)f goes on every part in those levels (as in Level), innermost first, with its full position pathTyped signatures
| Type | Package | Applies |
|---|---|---|
(function: any, list<any>, any?) -> list<any> | combinatorics | always |
Details
- The index arrives as a position path,
{i}at the top level, noti; with a level spec, a part at depth 2 gets{i, j}, and so on. - Without a level spec, f goes on the top-level parts only.
Examples
Scope #
live ↗
InOut
live ↗
InOut
live ↗
InOut
live ↗
InOut
live ↗
InOut
live ↗
InOut
live ↗
InOut
live ↗
InOut
live ↗
InOut
About
| Examples | 17 |
|---|---|
| Checked against | Wolfram Language 17 agree |
| Crosswalk | Wolfram Language |