Example 1 — Official Maximum
Find the largest number in a list.
_.max([4, 2, 8, 6]);
// → 8 How It Works
- Scan. Lodash walks the array once.
- Compare. Keeps the greater value at each step.
- Result.
8wins — same as the official docs. - Return. The element itself (not an index).

