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
12.求1-N的所有的最大N为数的解法有问题,我刚开始使用swift翻译之后,发现结果不对,然后我把你的代码粘贴到编辑器里,使用C++写,发现是你本身的代码有问题。
假设此时len = 2, "1,0",takeover = 1,走第一个方法内,nsum = 2,后面又有一个 nSum ++ ,导致sum变成3,高位变成30,直接越过了20-30的所有的数。
用你的代码的结果运行如下
The text was updated successfully, but these errors were encountered:
No branches or pull requests
假设此时len = 2, "1,0",takeover = 1,走第一个方法内,nsum = 2,后面又有一个 nSum ++ ,导致sum变成3,高位变成30,直接越过了20-30的所有的数。
用你的代码的结果运行如下
The text was updated successfully, but these errors were encountered: