Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

In 724, why pivot index = 0 is a valid solution? #22

Closed
surajwy opened this issue Jun 25, 2018 · 1 comment
Closed

In 724, why pivot index = 0 is a valid solution? #22

surajwy opened this issue Jun 25, 2018 · 1 comment

Comments

@surajwy
Copy link

surajwy commented Jun 25, 2018

Hi,

Can you please share your thoughts on why pivot index = 0 is a right answer?
I can see that in your solution at this line, you have purposely coded this condition (the first condition of OR construct).

The case for which this happens is:

[ -1, -1, -1, 0, 1, 1]

Would request you to reply over this discussion thread and share your thoughts. Lot of people are having same doubt.

Thanks.

@fishercoder1534
Copy link
Owner

Thanks a lot for opening an issue here. It's been a while I logged into Leetcode.
I just replied to that thread.
Happy coding! ^_^

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants