<DECISIONS>

Key Concepts

  • Boolean Algebra
  • Conditional Expressions
  • Control Structures
    • if/then
    • switch

<Boolean Algebra>

  • Values: true/false (1/0)
  • Operators: AND, OR, NOT

1815~1864

British teacher, mathematician, logician, and philosopher whose book, The Laws of Thought, mathematized the rules of logic of Aristotle.

 

Later known as "Boolean algebra," these techniques form the foundation for nearly all of modern computing.

Truth Tables

x y x AND y
0 0 0
0 1 0
1 0 0
1 1 1
x y x OR y
0 0 0
0 1 1
1 0 1
1 1 1
x y x XOR y
0 0 0
0 1 1
1 0 1
1 1 0
x NOT x
0 1
1 0

</Boolean Algegra>

<Conditional Expressions>

Conditional Expression

Any expression that can be reduced to a value of
true or false.

Conditional Operators

In addition to the Boolean operators,
conditional operators include comparison operators,
such as greater than (>) and less than (<)

 

(scroll down to see conditional operators in a variety of programming languages)

JavaScript:

Made with Slides.com