De Morgan's rules explained

前端 未结 8 1096
春和景丽
春和景丽 2020-11-27 04:58

Could you please explain the De Morgan\'s rules as simply as possible (e.g. to someone with only a secondary school mathematics background)?

8条回答
  •  爱一瞬间的悲伤
    2020-11-27 05:28

    Not sure why I've retained this all these years, but it has proven useful on a number of occasions. Thanks to Mr Bailey, my grade 10 math teacher. He called it deMorgan's Theorem.

    !(A || B) <==> (!A && !B)
    !(A && B) <==> (!A || !B)
    

    When you move the negation in or out of the brackets, the logical operator (AND, OR) changes.

提交回复
热议问题