Results are:my $y = 40.88050; $y = sprintf "%.3f", $y; my $x = 41.78050; $x = sprintf "%.3f", $x; print "$y \n $x\n";
As far as my wife, 10-year-old, and I can figure this is wrong - they should both end in a 0 or a 1 depending on if even or odd rounding is the rule.40.880 41.781
40.881 41.780
In reply to Rounding error? by dracos
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |