{{tag>Brouillon Math}} = Logique - Algèbre de Boole Voir : * [[https://fr.m.wikipedia.org/wiki/Alg%C3%A8bre_de_Boole_(logique)]] * Table de vérité * Tableau de Karnaugh * Théorème de Morgan * https://math.univ-lyon1.fr/irem/IMG/pdf/booleen-2.pdf **Ne pas confondre la logique booléenne avec la logique aristotélicienne / scolastique ! ** == En Python Voir : * https://docs.sympy.org/latest/modules/logic.html * https://ailtonbsj.github.io/simplifying-boolean-logic-expressions-with-sympy * https://booleanpy.readthedocs.io/en/latest/users_guide.html * https://stackoverflow.com/questions/52416781/how-to-simplify-these-boolean-statements Voir aussi : * [[https://www.editions-eni.fr/open/mediabook.aspx?idR=93202c4464ec21389d24b5da694ce63d|Algorithmique - Techniques fondamentales de programmation Exemples en Python]] == En bash === combine (moreutils) echo aaa > a.txt echo bbb > b.txt echo common | tee a.txt b.txt $ cat a.txt aaa common $ cat b.txt bbb common $ combine a.txt and b.txt common $ combine a.txt or b.txt aaa common bbb common $ combine a.txt xor b.txt aaa bbb $ combine a.txt not b.txt aaa $ combine a.txt or b.txt |sort | uniq aaa bbb common