22 lines
374 B
Plaintext
22 lines
374 B
Plaintext
func num_divisors[n: i64] : i64
|
|
end := math.isqrt(n)
|
|
|
|
out := 0
|
|
for i in 1..end+1
|
|
if n % i == 0
|
|
out = out + 2
|
|
|
|
if end * end == n
|
|
out = out - 1
|
|
return out
|
|
|
|
func main[] : i64
|
|
n := 0
|
|
i := 1
|
|
while true
|
|
n = n + i
|
|
if num_divisors(n) > 500
|
|
io.println_i64(n)
|
|
break
|
|
i = i + 1
|