This program finds the minimum number of rectangular buildings needed given an array of their required height. It has a time complexity of O(N).