0% found this document useful (0 votes)
65 views3 pages

Advice Generator

Uploaded by

api-557859698
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
65 views3 pages

Advice Generator

Uploaded by

api-557859698
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 3

CT Focus: Automation

Cross-Curricular Ties: English and Language Arts, SEL


Age Range: 10-16
Duration: 45 minutes

Vocabulary:
Algorithm: A list of steps that can be followed to carry out a task
Automation: Having a machine (such as a computer) do work for us, so that we don’t have to do it ourselves
Pseudocode: Instructions that look like they could be a computer program, but they are easier to read and
don’t necessarily follow rules of any specific programming language.

Lesson objectives:
Students will be able to:
● Break sentences apart into appropriate sections for randomization
● Compose sentences from random pieces
● Write an algorithm that explains the actions that explains the actions that the student’s “machine”
should take to automate the sentence-building procedure

Materials and Resources


● Paper
● Pencils
● Whiteboard
● Paper cups (3 per group)

Activity
Step 1. Introduction
Chat about algorithms
● Has anyone heard of an algorithm before?
○ What is it?
○ What do you think it might be?
● An algorithm is just a list of instructions that you can follow to finish a task. It’s like a recipe or a step-by-
step tutorial for modding your video game.
○ What else can you think of that might be an algorithm?
Have students create an algorithm for their school day (focusing on passing periods).

Allow your class to come up with a couple more algorithms, until you’re comfortable
that they understand what an algorithm is. You might want to take the opportunity
to let the students create one with a neighbor and share it with the class.

Algorithms let us prepare things for automation.


● Has anyone heard the term automation before?
○ What does automation mean to you?
○ Doing something automatically?
○ Having a machine do our work?
● Essentially it’s having a machine or tool do work for us so that we don’t have to do it ourselves. What
do you use daily that automates things for you?
○ A calculator
○ A car
○ A printer
● What does it automate, do you suppose?

Step 2. Program and run: One person will be the “machine,” and everyone else will be part of the
programming team.

Share advice for students:


● Always be on time for class.
● Make sure to do your homework.
● Always sleep for 8 hours a night.
● Daily check Google Classroom.

List the advice on the board.


● What do all of these pieces of advice have in common? (structure, positive statements)
● Would they still work if we mix them up?
○ Successful students do their homework.
○ Wise students sleep for 8 hours a night.
○ Organized students check Google Classroom.
○ Responsible students are on time for class.
● How can we break down these statements of advice?
○ Successful
○ Wise
○ Organized
○ Responsible
○ students
○ do their homework
○ sleep for 8 hours a night
○ check Google Classroom
○ are on time for class
● Where should the description (adjective) of the students be? (first word)
● What follows the adjective? (Subject: students)
● What follows “students”? (verb)
● What follows the verb? (a positive action)
● Can the verbs be mixed around or do they need to be connected with the positive action? (not all of the
can be mixed up -- that would be silly)
● Do you see any other patterns?
● What other chunks/phrases could we add? Could we swap out the word “students” for something else?
(Freshmen, Royals, kids, etc.)
○ Randomly assemble some phrases together

Now that your class sees where this is going, it’s time for them to get in their groups to think about how this
works. Give them these activity steps:
1. Create 6–10 phrases that fit the template above.
2. Cut the phrases into individual strips, then cut the strips into three appropriate chunks for mixing.
3. Label one cup “Description” and put all the chunks of sentence beginnings in that cup. Do the same for
“people” and “advice.”
4. Create an algorithm for your “advice generator machine” (AGM) using pseudocode.
a. What steps will your AGM need to follow in order to generate a new compliment each time you
run it?
b. How specific do you need to be to make sure your program runs without any errors?
c. Don’t forget to include steps for what to do with the papers after the advice has been delivered.
5. Program the AGM by reading it your algorithm.
6. Run the AGM to see if it had the desired result.
7. If there was a problem (bug), fix your algorithm, then program and run the CGM again.

Step 3. Share: When students have finished their generators, allow each group to run their generator for the
class. Did every CGM work the same?

Step 4. Discuss together: Gather the students together to talk about their experience.
● What was the hardest part of automating this task?
● Did you get the chance to look for issues with your algorithm and fix it for a better automation?
● Can you think of other tasks that you could create an algorithm for?
● What do you think the relationship is between algorithms and automation?

Step 5. In the real world


Algorithms are without a doubt the most important part of automating, and automation is the single largest
motivation for developing computer programs. Computer scientists wouldn’t even be necessary if we didn’t
need to automate.

More than 4,000 years ago, mathematicians were already trying to automate complex calculations using the
abacus. From that point, calculators (and soon computers) became more and more intelligent. Now, they are
able to automate tasks like finding unbelievably large prime numbers or sequencing the human genome—jobs
that just couldn’t be done by hand.

Behind every computer automation there is a computer program, and behind every computer program, there is
an algorithm.

Retrieved from the companion website for Computational Thinking and Coding for Every Student: The
Teacher’s Getting-Started Guide by Jane Krauss and Kiki Prottsman. Copyright © 2017 by Corwin. All rights
reserved. Thousand Oaks, CA: Corwin, www.corwin.com

You might also like