Fixed bug in checkvalidisbn()

This commit is contained in:
tonnesen 2002-07-03 03:18:50 +00:00
parent d6f9a61c7d
commit 17bb4d7343
1 changed files with 1 additions and 1 deletions

View File

@ -74,7 +74,7 @@ sub checkvalidisbn {
my $digit=substr($q,$i,1);
$c+=$digit*(10-$i);
}
$c=int(11-($c/11-int($c/11))*11+.1);
$c=$c%11; # % is the modulus function
($c==10) && ($c='X');
if ($c eq $checksum) {
$isbngood=1;