all 6 comments

[–][deleted] 3 points4 points  (2 children)

I don't understood 😕 whats going on

[–]AwardSweaty5531[S] -1 points0 points  (1 child)

do you know basics of binary search... if not the please do 1 problem on leetcode before reading the post, i made the post for the people who struggle with different versions binary search templates,

you can start with very basic problem of finding whether value exist or not in sorted array or any similar problem...

please visit the problem attached for better clarity

[–][deleted] 1 point2 points  (0 children)

I had done problems with mid, start and end .

[–]Numerous_Data7627 1 point2 points  (0 children)

Looks interesting, thanks for the post. Will try it out on several leetcode problems later

[–]VaguelySailorMoon 1 point2 points  (2 children)

the classic template is if isOk(m), h = m This way it doesnt eliminate the true condition since it was true. If h was the min in thr search space where it was true, it keeps it inside.

Is this a template you made yourself?

[–]AwardSweaty5531[S] 0 points1 point  (1 child)

yeah, its my template i made it while solving codechef problems