solulubeta
Sign in
Story Problems / Stack
03.05 · Problem

Biggest Banner in the Skyline

Hard Monotonic stack (largest rectangle in a histogram) Pro

This problem is part of solulu Pro

A skyline is a row of buildings of width 1 with the given heights. You want to hang a rectangular banner that must fit completely inside the skyline outline (it may cover several adjacent buildings, and its height cannot…

Lifetime ₹2,000 ₹1,000 · Beta offer
Mark this problem as solved when you are finished.

Item 45 of 94 · updated 2026-10-12