using Primes

function Triangle(n)

return sum(1:n)

end

num=1

temp=3

while num<500

```
A=collect(factor(Triangle(temp)))
if prod(i->A[i][2]+1, 1:length(A) )<500
temp+=1
else
num=5000
ans=Triangle(temp)
end
```

end

print(ans," " ,Triangle(temp))

I’m puzzled by why ans gives nothing, while its expected to be 76576500. Any explanation will be greatly appreciated.