Help rahul- binary search

i dont understand the concept used behind this problem.

This is a application of modified binary search and this is generally asked in interviews

u need to first watch the video of search in rotated sorted array
that is in a little more detail
after that understanding this becomes more easy https://codingblocks.com/resources/search-rotated/