U

UNPLUGGED

Variables in Envelopes


Lesson time: 20 Minutes         Basic lesson time includes activity only. Introductory and Wrap-Up suggestions can be used to delve deeper when time allows.

Lesson Overview

Variables allow for a lot of freedom in computer science. This lesson helps to explain what variables are and how we can use them in many different ways. Use this activity before (or in conjunction with) the lesson on abstraction to really hit the idea home.

Teaching Summary

Getting Started - 10 minutes

1) Review
2) Vocabulary
3) Introducing Variables

Activity: Envelope Variables - 20 minutes

4) Envelope Variables

Wrap-up - 10 minutes

5) Flash Chat: What did we learn?
6) Vocab-Shmocab

Assessment - 10 minutes

7) Variables Assessment

Lesson Objectives

Students will:

Teaching Guide

Materials, Resources and Prep

For the Student

For the Teacher

Getting Started (10 min)

1) Review

This is a great time to review the last lesson that you went through with your class. We suggest you alternate between asking questions of the whole class and having students talk about their answers in small groups.

Here are some questions that you can ask in review:

Lesson Tip

Finishing the review by asking about the students' favorite things helps to leave a positive impression of the previous exercise, increasing excitement for the activity that you are about to introduce.

2) Vocabulary

This lesson has one important word to review:

Variable - Say it with me: Vayr-ee-ah-buhl
A placeholder for a piece of information that can change

3) Introducing Variables

Call 4 volunteers to the front of the room and line them up. Let the students know that you are going to write a poem for each of them.

On the board (or under your document camera) write the sentence for your first student (suppose it's Bill):

"My student Bill, standing proud
is a fine example for the crowd"

Encourage the students to clap at your abilities and thank Bill for volunteering. Allow Bill to sit down (or go to the back of the line) as you erase the board, then call the next volunteer (we'll say that she's called Annie).

"My student Annie, standing proud
is a fine example for the crowd"

Again, accepting applause, erase the board and invite the next volunteer.

"My student Jenny, standing proud
is a fine example for the crowd"

As you call the final volunteer, inquire as to whether everyone in the class would like a poem written about them. Maybe the whole school? Goodness, that's going to take a while! Pose the question to your students:

"How could I do this more quickly?"

Your students will likely pick up on the fact that only one word is changing, and that word is simply a person's name. Help them see the location by circling Jenny's name on the board and writing "firstName" next to it.

"It would take a long time to write a poem for everyone in the school if I couldn't start until I knew who I was writing it about, wouldn't it?"

By this time, it's quite likely that you class will come up with the idea of having a placeholder. With that, they're most of the way into understanding where this lesson goes.

Now, let's add some more volunteers. Give them each a piece of paper to write their name on, and have them tuck it inside individual envelopes labeled firstName.

This time, put the poem on the board with a blank space labeled "firstName" where the student's name will go. - Have the first student in line (likely the last student from the previous example) pull their name from the envelope and that's what you'll write in the space. - When you erase the board, only erase the portion with the last student's name in it. - Call the next student to show their variable. - Repeat as many times as is entertaining

Now it's time for the main activity.

Activity: Envelope Variables (20 min)

4) Envelope Variables

Once the students understand how the envelopes relate to the sentences, pass out the Robot Variables activity and let them prepare some variables of their own.

Directions:

1) Divide students into groups of 2-4.

2) Have students design (draw) a robot.

3) After 10-15 min, request that the students fill their envelopes with important details about their robot.

4) Collect each group's envelopes, then bring them to the front of the room to share

5) Write on the board, "My robot's name is robotName, it is numUnitsTall tall, and it's purpose is purpose."

6) Use the envelopes to fill the appropriate variable in the sentence, then ask each group to stand when they hear the sentence that describes their creation.

Wrap-up (10 min)

5) Flash Chat: What did we learn?

6) Vocab Shmocab

You can choose to do these as a class, or have the students discuss with an elbow partner and share.

"A four sided parallelogram"
"A placeholder for a piece of information that can change"
"The wheels on the bottom of chair legs"

Assessment (10 min)

7) Variables Assessment Worksheet

Extended Learning

Use these activities to enhance student learning. They can be used as outside of class activities or other enrichment.

What's in the box?

Connections and Background Information

ISTE Standards (formerly NETS) Satisfied by this Lesson Include:

  • 1c. Use models and simulations to explore complex systems and issues
  • 2d. Contribute to project teams to produce original works or solve problems
  • 4b. Plan and manage activities to develop a solution or complete a project
  • 6c. Troubleshoot systems and applications

The activities in this lesson support CSTA K-12 Computer Science Standards:

  • CL.L2-03 Collaborate with peers, experts, and others using collaborative practices such as pair programming, working in project teams, and participating in group active learning activities
  • CT.L1:6-01 Understand and use the basic steps in algorithmic problem-solving
  • CT.L1:6-02 Develop a simple understanding of an algorithm using computer-free exercises
  • CPP.L1:6-05 Construct a program as a set of step-by-step instructions to be acted out

Next-Gen Science Standards

  • 3-5-ETS1-1 Define a simple design problem reflecting a need or a want that includes specified criteria for success and constraints on materials, time, or cost

Common Core Mathematical Practices

  • 2. Reason abstractly and quantitatively
  • 6. Attend to precision
  • 7. Look for and make use of structure
  • 8. Look for and express regularity in repeated reasoning

Common Core Language Arts Standards

  • L.3.6 Acquire and use accurately grade-appropriate conversational, general academic, and domain-specific words and phrases, including those that signal spatial and temporal relationships
  • L.4.6 Acquire and use accurately grade-appropriate general academic and domain-specific words and phrases, including those that signal precise actions, emotions, or states of being and that are basic to a particular topic
  • L.5.6 Acquire and use accurately grade-appropriate general academic and domain-specific words and phrases, including those that signal contrast, addition, and other logical relationships