That's a FAQ:
Found in C:\Perl\lib\pod\perlfaq4.pod
Does Perl have a round() function? What about ceil() and floor()? Trig funct
ions?
Remember that int() merely truncates toward 0. For rounding to a certain number of digits, sprintf() or printf() is usually the easiest route.
for more info: perldoc -q round
to answer your questions:
$rounded = sprintf("% .Xf", $number);
There shuld be no space between the % and the . but this forum does funny things to that. Replace X with the num of decimal places you want to round to
--mark
Installation support is provided via ICQ at UIN# 53788453. I will only respond on that number.