It says this problem is a follow up for Search in Rotated Sorted Array.
Search in Rotated Sorted Array is a hard level question.
It is kinda un-intuitive for a medium level question to be a follow up for a hard question since I am doing all medium level questions first before I do hard level questions.
If this problem is easier than Search in Rotated Sorted Array, then I think Search in Rotated Sorted Array should be the follow up problem for this, not the other way around.
I am not saying it matters. I am just saying that it is kinda un-intuitive. It is up to the admins of leetcode to decide whether they think it matters or not.
I would say there is a logic in that, if you consider this problem as a follow up, that is "given the solution to previous problem, modify it to accommodate the change in requirements". That way, it really looks like a "medium" problem to me.
Glad that I did the hard first, but did have the same thought as you at the first place.
I agree with you. Although some people don't really care , it could cause confusion for some others.
It's not only about logic.
Q81 has no explicit problem description, that means you have to read Q33 first to understand what is "Rotated Sorted Array", and then you'll found the question has no link to Q33. So better go back to the problem list to search...
Hi, I think the purpose of this follow-up is to test whether the interviewee could figure out the duplicates would lead to a O(N) worst case, rather than modify the previous implementation since it is not much worthy than a O(N) linear search in this case.
@whiteSkar Yeah I agree with you :)
Looks like your connection to LeetCode Discuss was lost, please wait while we try to reconnect.