Proper divisors: Difference between revisions
m
→{{header|Sidef}}: modified the code to work with Sidef 2.30
m (→{{header|Sidef}}: modified the code to work with Sidef 2.30) |
|||
Line 2,516:
divs << 1 if (x > 1)
for d in (2 ..
var y = (x // d)
if (y*d == x) {
Line 2,527:
}
10.times { |i| say "#{i}\t#{propdiv(i)
var max = 0
var candidates = []
20_000.times { |i|
var divs = propdiv(i).len
if (divs > max) {
Line 2,540:
}
say "max = #{max}, candidates = #{candidates
{{out}}
<pre>
|