what is logic
- study of formal reasonaing
- basis of all mathematical reasoning
- numerous application in cs, math etc
what is a proposition
- truth value of a proposition indicates whether the proposition is true or false
- propositions can be combined using logical operators
- statement that is either true or false
- declarative sentences
logical operators:
-
negation - not
-
conjunction - and
-
disjunction - or
-
compound propositions are multiple propositions put together using operators
operators
negation:
- NOT
“it is not the case that p”
p: there is a car in the room -p : there is not a car in the room
conjuction:
- AND
disjunction:
- OR
exclusive or:
- either this or that
lucy is going to the movie or the park
- denoted by

inclusive or
- same as OR
lucy opens the windows or doors when warm ( can be either one or both - normal OR condition - inclusive )
compound propositions
order of operation:
- negation first, then and, then or