Don't laugh at where I have defined the variables.I did that many months ago,code style unlike now.
We can use sort after changing the divisors' value,but the code which changes them to -14248 runs faster.It's 15ms faster than the other.Why is this happening?
The submission times are rounded and not exact, so that probably is just a small testing system bug. You can expect variance of like 2-3 ms, and if rounded, may seem like it is 15 milliseconds. If you really want to check the time — generate random testcases, run each code 10 times, and take the average. You probably won't see any difference.