Why it matters
Shoelace is fundamental polygon formula. Understanding shapes basics.
Advertisement
The architecture
Area = 0.5 * |sum of (x_i * y_{i+1} - x_{i+1} * y_i)|.
Signed area indicates orientation.
Advertisement
How it works end to end
O(n).
Signed: CCW positive.
Works for simple polygons.