This one is quite simple.
Lets say that I want to add some "premature optimizations" to my code.
I need to round the result of some calculation.
Instead of:
I'm using:
1. Will it work correctly?
2. Will it ALWAYS work correctly?
Lets say that I want to add some "premature optimizations" to my code.
I need to round the result of some calculation.
Instead of:
B4X:
Dim i As Int = Round(d / f)
B4X:
Dim i As Int = (d / f) + 0.5
1. Will it work correctly?
2. Will it ALWAYS work correctly?