I would say for code that is executed one time ever, even including the sqrt(n) part is premature optimization (though I did include it)
I would say for code that is executed one time ever, even including the sqrt(n) part is premature optimization (though I did include it)