Histogram largest area rectangle


what is error in it

Hey @vikashkmr519,
The answer may exceed the range of int since the test cases are large. Use long instead of int.

https://ide.codingblocks.com/s/147524 i have made changes still giving error please check and tell me sir

@vikashkmr519,
n is undefined and hist is also undefined. Kindly recheck and remove these errors. Your logic looks correct.

its giving run time error

Hi @vikashkmr519,
I have corrected your code https://ide.codingblocks.com/s/148145. There was a small bracket error in line 40. Kindly compare this with your code and ping me for any further queries.