Help required in "Chef and Array - FRMQ" problem

Can anyone help me out, or tell me why am I getting a WA ?

Solution Approach : I’ve used standard sparse table approach to solve the problem. You could easily figure that out from the implementation.

I know this is hard-core optimization problem, but I’m unable to get even 70 points. It’d be really helpful if anyone could point out my mistake, or tell me where I’m possibly going wrong.

Solution Link

Access denied! .

Sorry! I shared the submission status, and not the submission code. I’ve changed it, please check now.

You are not creating the Sparse table in a correct way . REFER to the below pink