and¶
Description¶
and sets as a condition that both expressions have to be true, for the entire expression to evaluate to true.
Unknown values¶
and follows three-valued logic. Because a single false is enough to make the whole expression false, false and unknown is false, not unknown - the unknown side cannot change a false and, so the rule resolves to a definite false rather than staying pending. The expression only becomes unknown when the missing side could still flip the outcome (for example true and unknown).
and |
true | false | unknown |
|---|---|---|---|
| true | true | false | unknown |
| false | false | false | false |
| unknown | unknown | false | unknown |
Need the second question to be asked only after the first is answered? Use
and theninstead.
Example¶
If a bank only offers certain services to people who are a citizen of an EU member state, and also pay taxes in the European Union, this is how to check against both those requirements: