if ( $x and !$y ) { .. # true, false } elsif ( !$x and $y ) { .. # false, true } else { .. # true, true or false, false }