4.2 Space Ship

4-2 Compound Booleands: AND, OR, NOT

OBJECTIVES

Students gain practice with compound coditionals NOT, AND and OR compound by remixing a rocket launching project.

OBJECTIVES: By the end of this lesson, students will:

    • Understand compound Booleans And , Or, Not

TEACHER RESOURCES:

Standards

    • CSTA 2-AP-13: Decompose problems and subproblems into parts to facilitate the design, implementation, and review of programs.

    • CSTA 2-AP-11: Create clearly named variables that represent different data types and perform operations on their values.

CSTA

Do Now (5 minutes)

Do Now Diversity in Technology (5 minutes)

    1. Watch "Aloe Blacc: control your destiny" (1:50)

    2. Discuss:

      • What Aloe's passion?

      • When did he start learning to program?

      • How does he use the computer his achieve his goals

      • Aloe says " Knowledge is power". Discuss.

TEACHER GUIDANCE:

  • Music particular Hip Hop. Aloe started to program when he was 6.

  • He mixes his music, samples, he has a website, he has an online present where people can find out about him and buy his music.

  • Remember that all code is made by humans, knowledge is power and if you have the knowledge of the parts you can control the outcomes.

Mini-Lesson (5-10 minutes)

Project (20-30 minutes)

Fix starter project, so that the Rocket will takeoff, if certain conditions are met:

  • Pilot is in rocket ship

  • Safety button is clicked.

Close-Out (5 minutes)

Close-Out (5 minutes)

Discuss the following questions:

    1. Discuss the difference between the boolean operators AND, OR

Here are three boolean ( Yes/No Statements).

        • I like Pizza,

        • I love puppies,

        • I am in school

2. How could you test that all three conditions are true at the same time?

3. How could you test that any one of three conditions is true at the same time?

Potential Responses

  • AND - all conditions need to be true for statement to be true

  • OR - only one condition needs to be true for statement to be true


2. Use AND

3. Use OR