jackfrued / jackfrued/Python-100-Days
Day5. 完美数程序或存在错误?
Open
Nobody has claimed this yet.
- Dominant language
- Jupyter Notebook
- Stars
- 187k
- Forks
- 55.8k
- PR merge metrics
- No merged PRs in 30d
Description
运行code中所给程序会得到答案1,但根据完美数的定义,1应该不属于完美数。下面是我编的程序。
for x in range(1, 10000):
i = 0
for factor in range(1, x - 1):
if x % factor == 0:
i += factor
if i == x:
print(x, end=' ')
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
The issue provides the complete Python loop but names no repository file or test. Run the supplied program and compare its output with the definition of a perfect number, paying particular attention to the boundary cases around 1. Done means the program no longer reports 1 and its output matches the stated definition.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100