Pergunta de entrevista da empresa Commvault

For a given array of integers, calculate the largest rectangle of histogram.