The rounding "error" is due to the fact that Excel uses 64-bit binary floating-point to represent numbers. Decimal numbers are approximated by a sum of 53 consecutive powers of 2 ("bit"). The highest (left-most) power of 2 is determined by the magnitude of the number.
Consequently, most decimal fractions (and integers greater than 2^53) cannot be represented exactly. And the approximation of a particular decimal fraction (e.g. 4/10) varies depending on the magnitude of the integer part.
Contrary to most online information, the precision of the binary sum is not limited to 15 significant digits. But Excel formats only up to 15 significant digits (rounded).
For your example, the exact values are shown by their equivalent decimal representation on the right.
I use period for the decimal point and comma to demarcate the first 15 significant digits.
And yes, in general, when we expect a calculation to be accurate to n decimal places, we should explicitly round the calculation (usually by using ROUND) to that number of decimal places, not to an arbitrary number of decimal places like 10, as some people suggest.
Bookmarks