我对 Project Euler's problem no. 61 没有什么困惑,我正在尝试用 Java 来解决这个问题。我已经成功获得了六个四位数字,它们是:
4465, 6561, 6112, 1225, 2512, 1281
但是在汇总这些数字并提交我的答案后,我得到了错误的答案。谁能告诉我这些数字有什么问题吗?
最佳答案
来自问题陈述:
The set is cyclic, in that the last two digits of each number is the first two digits of the next number (including the last number with the first).
如果您不理解“循环”一词所暗示的含义,括号中的部分就很重要。您的解决方案没有此属性。
关于java - 欧拉项目问题 #61 中的困惑,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/4594887/