Next Program Repair Shop 64

GetPadString

     124        if ($Integer < 10) {
     125                return "0000".$Integer;
     126        } elsif (($Integer >= 10) and ($Integer < 100)) {
     127                return "000".$Integer;
        ...
        return sprintf "%05d", $Integer;
        my $n_zeroes = 5 - length($Integer);
        my $zeroes = '0' x $n_zeroes;
        return $zeroes . $Integer;
        while (length($Integer) < 5) { $Integer = "0$Integer" }
        return substr("00000$Integer", -5);


Next Copyright © 2002 M. J. Dominus