• + 0 comments
    def largestRectangle(h):
    	def checkR(number, index, h):
    			counter = 0
    			for element in range((index +1), len(h)):
    					if number <= h[element]:
    							counter+=1
    					else:
    							break
    			return counter
    
    	def checkL(number, index, h):
    			counter = 0
    			for element in reversed(range(index)):
    					if number <= h[element]:
    							counter+=1
    					else:
    							break
    			return counter