in reply to Best way to make sure a number is an even multiple of another?
sub fix{ my ($n,$m)=@_; my $M = $n % $m; $M && return $n + $m - $M; $n; } [download]
C.