# Largest Rectangle in Histogram (LC5421)

## Problem
Given bar heights, find largest rectangle area in histogram.

## Approach
Monotonic increasing stack of indices; when a lower bar appears, pop and compute width to new top. Sentinel 0 at end.

## Complexity
O(n).

## Practice
Stack geometry problems — rehearse with [AI tool for job interviews](https://www.linkjob.ai/).

## Notes
- Left/right smaller bounds
- Equal heights handling
- Add sentinel height 0
