version 1.149, 2011/06/07 17:27:37
|
version 1.150, 2011/08/26 22:40:17
|
Line 555 sub whichfoils {
|
Line 555 sub whichfoils {
|
$dosplice=0; |
$dosplice=0; |
} else { |
} else { |
if ($topcount>0 || $bottomcount>0) { |
if ($topcount>0 || $bottomcount>0) { |
$answer = int(&Math::Random::random_uniform() * ($#whichfalse+1)) |
my $inc = 1; |
+ $topcount; |
if (($bottomcount > 0) && ($Apache::lonhomework::type ne 'exam')) { |
|
$inc = 2; |
|
} |
|
$answer=int(&Math::Random::random_uniform() * ($#whichfalse+$inc)) |
|
+ $topcount; |
} |
} |
} |
} |
&Apache::lonxml::debug("Answer now wants $answer"); |
&Apache::lonxml::debug("Answer now wants $answer"); |