Search⌘ K
AI Features

Largest Rectangle in Histogram

Largest Rectangle in Histogram gives you bar heights and asks for the greatest area of a rectangle formed from consecutive bars, with each bar contributing one unit of width.

Statement

Given an array of integers, heights, that represents the heights of bars in a histogram, find the area of ...