Please help me in the 6 th march dcb i am not able to find one condition for the question

Please send a link to that question. This is not code for prateek loves candy question.

question link https://hack.codingblocks.com/app/dcb/1241

@kailash_01
Your approach is incorrect. You need to use a set of <value,pos> and iterate the array. Then at each pos, pick lower_bound of current element. Then do the same from right to left.

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.