Help for this page

Select Code to Download


  1. or download this
    my $pErr = 5; # for plus/minus 5.
    sub MakeP { my $p = $_[0]; $p -= $pErr; $p += int(rand() * 2 * ($pErr 
    ++ 0.5)); return $p / 100 }
    ...
            ++$count; shift @foo }
        printf "%f\t%6d\n", $next, $count;
    }
    
  2. or download this
    sub MakeP { 
       my $p = $_[0];
    ...
       $p += int( rand() * 2 * ( $e + 0.5 ) ); 
       return $p / 100
    }