Help for this page

Select Code to Download


  1. or download this
    sub list_reduce {
      my ( $top, $bot ) = map [ grep $_ != 1, @$_ ], @_;
    ...
      my $gcd = Math::BigInt::bgcd( $top, $bottom );
      return ( $top/$gcd, $bottom/$gcd );
    }
    
  2. or download this