3 ms·
1.5 has an exact representation in floating-point, so adding 1.5 + 1.5 is always going to give you 3.0 in floating-point, also exactly represented. Then whatev
by p0nce 11y ago
1.5 has an exact representation in floating-point, so adding 1.5 + 1.5 is always going to give you 3.0 in floating-point, also exactly represented.
Then whatever the type of integer rounding you do, you will get a solid 3.