Possible Duplicates:
07000
07001
#!/usr/bin/perl $l1 = "0+0.590580+0.583742+0.579787+0.564928+0.504538+0.459805+0.433273+0.384211+0.3035810"; $l2 = "0+0.590580+0.583742+0.579788+0.564928+0.504538+0.459805+0.433272+0.384211+0.3035810"; $val1 = eval ($l1); $val2 = eval ($l2); $diff = (($val1 - $val2)/$val1)*100; print " (($val1 - $val2)/$val1)*100 ==> $diff\n";
令人惊讶的是,输出最终结果是
((4.404445 - 4.404445)/4.404445)*100 ==> -2.01655014354845e-14.
它不应该是一个零吗????
请任何人解释一下……