We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
https://zuodexin.github.io/2020/11/17/leetcode525%E7%9B%B8%E5%90%8C%E4%B8%AA%E6%95%B001%E7%9A%84%E6%9C%80%E9%95%BF%E8%BF%9E%E7%BB%AD%E5%AD%90%E6%95%B0%E7%BB%84/#more
维护变量count,遇到0减1,遇到1加一,记录遇到count的最早位置,下次遇到后计算长度,画个折线图就能理解为什么这两个位置间的01个数相等。 扩展一下,以后遇到这种相等的可以考虑一下这种折线图的解法。
The text was updated successfully, but these errors were encountered:
No branches or pull requests
https://zuodexin.github.io/2020/11/17/leetcode525%E7%9B%B8%E5%90%8C%E4%B8%AA%E6%95%B001%E7%9A%84%E6%9C%80%E9%95%BF%E8%BF%9E%E7%BB%AD%E5%AD%90%E6%95%B0%E7%BB%84/#more
维护变量count,遇到0减1,遇到1加一,记录遇到count的最早位置,下次遇到后计算长度,画个折线图就能理解为什么这两个位置间的01个数相等。 扩展一下,以后遇到这种相等的可以考虑一下这种折线图的解法。
The text was updated successfully, but these errors were encountered: