Anonymous user
Practical numbers: Difference between revisions
→{{Header|Python}}: Alternate
(→{{Header|Python}}: Alternate.) |
(→{{Header|Python}}: Alternate) |
||
Line 83:
; Alternate version:
This version
A number with a large number of factors, f has <code>2**len(f)</code> sets in its powerset. 672 for example has 23 factors and so 8_388_608 sets in its powerset.<br>
Just taking the sets as they are generated and stopping when we first know that 672 is Practical needs just the first 28_826 or 0.34% of
the sets. 720, another Practical number needs just 0.01% of its half a billion sets to prove it is Practical.
Note however that if the number is ```not```
===Or, as a composition of pure functions===
|