sub round_to_halves { return 0.5 * (int(2*$_[0])); } my $num = 1.6; print round_to_halves($num), "\n";
In reply to Re: Round down to '.5' or '.0'
by moritz
in thread Round down to '.5' or '.0'
by awohld
For: | Use: | ||
& | & | ||
< | < | ||
> | > | ||
[ | [ | ||
] | ] |