We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4be218d commit 20875e9Copy full SHA for 20875e9
maths/special_numbers/deficient_numbers.py
@@ -39,6 +39,8 @@ def is_deficient_number(number: int) -> bool:
39
raise TypeError(msg)
40
if number < 1:
41
return False
42
+ if number == 1:
43
+ return True
44
45
divisor_sum = 1
46
for i in range(2, int(number**0.5) + 1):
@@ -50,4 +52,4 @@ def is_deficient_number(number: int) -> bool:
50
52
51
53
if __name__ == "__main__":
54
import doctest
- doctest.testmod()
55
+ doctest.testmod()
0 commit comments