Exemple #1
0
        public void _3_01_should_construct_truth_tables_for_logical_expressions()
        {
            var expected = new List <(bool, bool, bool)>
            {
                (true, false, true),
                (true, true, true),
                (false, false, false),
                (false, true, false),
            };

            var actual = LogicAndCodes._3_01((a, b) => LogicalPredicates.And(a, LogicalPredicates.Or(a, b)));

            CollectionAssert.AreEqual(expected, actual);
        }
Exemple #2
0
 public static bool Or(this bool a, bool b)
 {
     return(LogicalPredicates.Or(a, b));
 }
Exemple #3
0
 public static bool And(this bool a, bool b)
 {
     return(LogicalPredicates.And(a, b));
 }
Exemple #4
0
 public static bool Equ(this bool a, bool b)
 {
     return(LogicalPredicates.Equ(a, b));
 }
Exemple #5
0
 public static bool Not(this bool a)
 {
     return(LogicalPredicates.Not(a));
 }