Help for this page

Select Code to Download


  1. or download this
    sub almost_normal {
        my ($mean, $variance) = @_;
        return sqrt($variance) * atan2( rand(2) - 1, 1 ) + $mean;
    }
    
  2. or download this
    #!/usr/bin/perl -slw
    
    ...
    printf "%7.2f : %-3d : %s\n", $_, 
        $plot{ $_ }, '#' x ( $plot{ $_ } / $ITERS * 100 * $PRECISION )
        for sort{ $a <=> $b } keys %plot;