--- loncom/homework/default_homework.lcpm 2002/09/26 20:46:48 1.52 +++ loncom/homework/default_homework.lcpm 2002/11/13 23:05:46 1.54 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # used by lonxml::xmlparse() as input variable $safeinit to Apache::run::run() # -# $Id: default_homework.lcpm,v 1.52 2002/09/26 20:46:48 albertel Exp $ +# $Id: default_homework.lcpm,v 1.54 2002/11/13 23:05:46 albertel Exp $ # # Copyright Michigan State University Board of Trustees # @@ -101,11 +101,11 @@ sub caparesponse_check { $sig_ubound =15; #SIG_UB_DEFAULT } else { ($sig_lbound,$sig_ubound) = split /,/,$sig; - if (!$sig_lbound) { + if (!defined($sig_lbound)) { $sig_lbound = 0; #SIG_LB_DEFAULT $sig_ubound =15; #SIG_UB_DEFAULT } - if (!$sig_ubound) { $sig_ubound=$sig_lbound; } + if (!defined($sig_ubound)) { $sig_ubound=$sig_lbound; } } my $result = &caparesponse_capa_check_answer($response,$answer,$type, $tol_type,$tol, @@ -240,7 +240,8 @@ sub hinton { sub random { my ($start,$end,$step)=@_; if ( ! $hidden::RANDOMINIT ) { - &random_set_seed_from_phrase($external::randomseed); + &random_set_seed(1,$external::randomseed); + &math_random_uniform(); $hidden::RANDOMINIT=1; } if (!defined($step)) { $step=1; }