Last
The last element of a collection.
✓ checked against that system · ! checked, with disagreements (hover a chip)Wolfram Language
Last!Last(collection)the last element of the collection.Last(collection, default)default when the collection is empty, instead of the last element.Last(expr)the last operand of any expression, not just a collection.Typed signatures
| Type | Package | Applies |
|---|---|---|
(xs: indexed_collection<any>) -> any | compute-engine | always |
(any, any?) -> any | combinatoricsreplaces compute-engine | always |
Details
Examples
3 more kept as data, checked against the oraclesAbout
| Examples | 17 |
|---|---|
| Checked against | Wolfram Language 15 agree1 differ1 unevaluatedmathlib4 4 agree1 error |
| Crosswalk | Wolfram Language |
Implementation
mapped
mathlib4packages/oracle/src/mappings.tsThe last element of a list; an empty list fails to elaborate (ours is Missing) rather than defaulting, and so does an expression that is not a list.