Staircase search algo

can you check my code for that case…
url -https://ide.codingblocks.com/s/252951…

Hello @Sitikant,

There are multiple missing cases that is causing TLE.
I have corrected your code:


Refer to comments for better understanding.

Hope, this would help.
Give a like if you are satisfied.

1 Like

thanks bhaiya… I was missing the break statement…