How do I round a number to a decimal place?
Look at the first digit past the place you want. If it is 5 or more, round up; otherwise round down. For 3.472 to one decimal place the next digit is 7, so the answer is 3.5. Equivalently, and more honestly: pick whichever of 3.4 and 3.5 is nearer.
Does 5 always round up?
Under the rule taught in school, yes - and a lone 5 is the one case where the two neighbours are equally near, so the rule is a convention rather than a fact. Other conventions exist and are widely used: rounding to the even neighbour, rounding down, or rounding towards zero.
What is bankers' rounding and why does it exist?
Round-half-to-even: a tie goes to whichever neighbour is even, so 2.5 becomes 2 and 3.5 becomes 4. Always rounding ties up biases a long column of figures upward; sending half of them down cancels that bias out. It is the default in IEEE floating point and in several statistical packages.
How do I round to significant figures?
Count from the first non-zero digit rather than from the decimal point, then round at that place. 0.004567 to two significant figures is 0.0046, and 123456 to three is 123000. This page works out where that place falls for you and then rounds normally.
Why does my calculator say 2.675 rounds to 2.67?
Because it never had 2.675. In binary floating point that value is stored as 2.67499999999999982…, which is genuinely below the halfway point, so the calculator is rounding correctly on the number it actually holds. This page keeps the number as an exact fraction, so it can see the tie your calculator cannot.
How do negative numbers round?
Depends on the convention, which is exactly why this page shows all six. The school digit rule rounds away from zero, giving -3 for -2.5. A ceiling goes towards positive infinity (-2), a floor towards negative infinity (-3), and truncation towards zero (-2).
What is the difference between rounding and truncating?
Truncating drops everything past the place, no matter what it says: 3.99 truncated to a whole number is 3. Rounding picks the nearer neighbour, so 3.99 becomes 4. Truncation is faster and always biased towards zero, which is why it is fine in a loop counter and dangerous in money.
Where in a calculation should I round?
At the very end. Rounding intermediate values throws away information you still need, and the errors accumulate: this is why the exact answers on these pages keep fractions as fractions and radicals as radicals until you ask for a decimal.