Help for this page

Select Code to Download


  1. or download this
    sub dec2bin {
        my $str = unpack("B32", pack("N", shift));
    #    $str =~ s/^0+(?=\d)//;   # otherwise you'll get leading zeros
        return substr( $str, -6 );
    }
    
  2. or download this
    if( $value eq undef ) { ...
    
  3. or download this
    if( defined $value ) { ...
    
  4. or download this
    for my $i ( 0 .. 63 ) {
      ...
    }
    
  5. or download this
    $tree->{ ('left', 'right')[ rand 2 ] }
           { ('left', 'right')[ rand 2 ] }
           { ('left', 'right')[ rand 2 ] } = 'AND';;