Domanda di colloquio di Meta

They asked me Largest histogram problem .

Risposta di colloquio

Anonimo

7 set 2017

I started with the naive algorithm O(n^2) and then improved it to O(n log(n)) and after the interviewer asked me to improve more I finally improved it to O(n).