Search in a rotated array

Question:-https://leetcode.com/problems/search-in-rotated-sorted-array/submissions/

code link:-https://ide.codingblocks.com/s/378304

I think the implementation is correct but still getting wrong answer.

Hey @div_yanshu07
Line 27 should be

            if(target>=a[mid] and target<=a[end]) 

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.