RosettaCodeData/Task/Amicable-pairs/Phix/amicable-pairs-1.phix
2026-04-30 12:34:36 -04:00

5 lines
144 B
Text

with javascript_semantics
for m=1 to 20000 do
integer n = sum(factors(m,-1))
if m<n and m=sum(factors(n,-1)) then ?{m,n} end if
end for