Proper divisors: Difference between revisions

Content added Content deleted
(Proper divisors in various BASIC dialents)
Line 2,139: Line 2,139:
}
}
}
}

for i in 1..10 {
for i in 1..10 {
print("\(i): \(properDivs(i).toArray())")
print("\(i): \(properDivs(i).ToArray())")
}
}
Line 2,147: Line 2,147:
for i in 1..20000 {
for i in 1..20000 {
let count = properDivs(i).len()
let count = properDivs(i).Length()
if count > max {
if count > max {
set (num, max) = (i, count)
set (num, max) = (i, count)