Subject: | Dear Geoffrey Rommel and other great team members, may I report a bug of nearest in Math Round? |
Date: | Fri, 2 Nov 2007 10:04:47 +0800 |
To: | <bug-math-round [...] rt.cpan.org> |
From: | 李xc <li_xi_chen [...] hotmail.com> |
Dear Geoffrey Rommel and other great team members,
When using your great Math::Round module, I encounter a confusing situation, the code and result is list below:
===code begins
#!/usr/bin/perl use strict;
use Math::Round qw(:all);
my $before_nearest; my $after_nearest;
foreach $before_nearest(qw/-0.31266435 -0.21620515 -0.30837255/){ chomp; print $before_nearest . "\n"; $after_nearest = nearest(0.0000001, $before_nearest); print $after_nearest . "\n\n"; }
####################### #Output is listed here: # #-0.31266435 #-0.3126643 <--- Isn't this obviously wrong? # #-0.21620515 #-0.2162052 # #-0.30837255 #-0.3083726 #######################
===code ends
I hope I have made myself clear. I appreciate your effort on reading this problem and resolving this.
Best regards,
xichen li
2007-11-2
Show quoted text
_________________________________________________________________
手机也能上 MSN 聊天了,快来试试吧!
http://mobile.msn.com.cn/