Largest Rectangle gave WA although logic seems to be correct.

Please release the test cases for the following problem or review my code.
Problem link–> http://www.codechef.com/INIO1404/problems/LARGEST

My code–> http://ideone.com/hafPnP

Just to let you know, you can submit your solution here: http://www.codechef.com/problems/LARGEST

@sidhant007 Your code gives TLE.
Our test data generation solution: http://www.codechef.com/viewsolution/5329450

I got it AC 0.25 seconds. -> http://www.codechef.com/status/LARGEST,rajat1603
The test case is fine , and nice problem

Got AC, needed to use fast i/o and had an error in my recursion’s base case!