4 ms·
I'm surprised by how often programmers coming from software engineering background do this wrong. I started programming in science and there it's absolutely nec
by vjk800 3y ago
I'm surprised by how often programmers coming from software engineering background do this wrong. I started programming in science and there it's absolutely necessary to think about this stuff. Doing for loops in a wrong order can be the difference between running your simulation in one hour instead of one week.
With this background, I instinctively do small-time optimization to all my codes by ordering for's and if's appropriately. Code that doesn't do this right just looks wrong to me.
- crabmusket 3y agoWatch out for a visit from the premature optimisation police!
- topaz0 3y agoI try to avoid the premature optimisation police just as much as the regular police. Neither of them tend to be serving the public interest, whatever they may say.