23

Introduction, Computers work by following a series of steps. Computers work by following a series of steps. These steps organize objects (set of variables)

Embed Size (px)

Citation preview

Page 1: Introduction, Computers work by following a series of steps. Computers work by following a series of steps. These steps organize objects (set of variables)
Page 2: Introduction, Computers work by following a series of steps. Computers work by following a series of steps. These steps organize objects (set of variables)

Introduction,Introduction,

• Computers work by following a series of Computers work by following a series of steps.steps.

• These steps organize objects (set of These steps organize objects (set of variables) to reach a desired outcome.variables) to reach a desired outcome.

• In order to manipulate the objects as we In order to manipulate the objects as we would like, we must first clearly identify would like, we must first clearly identify them.them.

• In the real world this can be difficult In the real world this can be difficult because a single description may apply to because a single description may apply to many different objects.many different objects.

Page 3: Introduction, Computers work by following a series of steps. Computers work by following a series of steps. These steps organize objects (set of variables)

exampleexample,,

Bobby is the name of three different Bobby is the name of three different boys in the class. boys in the class.

• An additional descriptions would have An additional descriptions would have to be added, such as Bobby the red to be added, such as Bobby the red head, Bobby the blonde and Bobby with head, Bobby the blonde and Bobby with the dark hair.the dark hair.

• If hair color is a different characteristic If hair color is a different characteristic then it is another method that can then it is another method that can distinguish students.distinguish students.

• If their name and hair color are the If their name and hair color are the same then a different description would same then a different description would be needed.be needed.

Page 4: Introduction, Computers work by following a series of steps. Computers work by following a series of steps. These steps organize objects (set of variables)

Introduction continued,Introduction continued,

• Once the objects have been clearly defined Once the objects have been clearly defined then you must also clearly describe what then you must also clearly describe what you are doing with the object (the you are doing with the object (the function).function).

• Like the description of the object, the Like the description of the object, the description of the description of the functionfunction must be must be described consistently.described consistently.

Page 5: Introduction, Computers work by following a series of steps. Computers work by following a series of steps. These steps organize objects (set of variables)

Example,Example,

There are four boxes on the floor There are four boxes on the floor being loaded. You are asked to place being loaded. You are asked to place objects in the boxesobjects in the boxes

• For the instruction to be followed For the instruction to be followed consistently, you would need to be consistently, you would need to be told which of the boxes to place the told which of the boxes to place the objects in.objects in.

• An additional identifier must be An additional identifier must be placed with the function, such as placed with the function, such as the color, size, location, content ...the color, size, location, content ...

Page 6: Introduction, Computers work by following a series of steps. Computers work by following a series of steps. These steps organize objects (set of variables)

In order to write good instructions, we most use some common vocabulary to describe specific situations.

Common Common VocabularyVocabulary,

Identifying Lego Pieces Identifying Lego Pieces (objects)(objects)

Identifying PiecesIdentifying Pieces, , by ColorColor &

TypeTypeColors

TypeHalf Full

Page 7: Introduction, Computers work by following a series of steps. Computers work by following a series of steps. These steps organize objects (set of variables)

ExamplExampleses,

Full White

Half a Green

Full Blue

Half a Yellow

Lego Pieces (objects) Lego Pieces (objects) will also be identified by when the pieces entered the instructions.

Page 8: Introduction, Computers work by following a series of steps. Computers work by following a series of steps. These steps organize objects (set of variables)

What color is OverOver the other

Is it connected with a set of Single Single Poles Poles or Double Poles Double Poles

The Number Number of connections

(White)

(Green)(White over Green)

(3 double poles)

Common VocabularyCommon Vocabulary,Identifying Connections of Lego Pieces Identifying Connections of Lego Pieces

(Functions)(Functions)

Page 9: Introduction, Computers work by following a series of steps. Computers work by following a series of steps. These steps organize objects (set of variables)

A full white --- over --- a full green --- 2 --- double posts --- inline

A full white --- over --- a full green --- 2 --- single posts --- inline

ExamplExampleses,

A half blue --- over --- a full green --- 2 --- double posts

A full green --- over --- a half blue --- 2 --- double posts --- middle

NoticeNotice an additional statement at the end of first and last example, used to clarify how the pieces are connected.

Page 10: Introduction, Computers work by following a series of steps. Computers work by following a series of steps. These steps organize objects (set of variables)

Let’s build this, (virtually)

Page 11: Introduction, Computers work by following a series of steps. Computers work by following a series of steps. These steps organize objects (set of variables)

A half yellow over a full yellow, 2 double posts in the middle.A full white over a full green, 2 double posts, other side.A full blue over a half yellow, 1 double post.A full blue (same blue as before) over a half yellow, 1 double post.A half yellow (the one just attached) over a full yellow, 2 double posts, in the middle.

A half white over a full blue, 1 double post, other side.A half white over a full blue, 1 double post.One full green over two half white, 1 double post, empty middle.Let’s build this,SuccesSucces

s!s!

Page 12: Introduction, Computers work by following a series of steps. Computers work by following a series of steps. These steps organize objects (set of variables)

.

.

1. A half yellow over a full yellow, 2 double posts in the middle.

2. A full Blue over a half yellow, 1 double post.3. A full blue (same blue as before) over a half

yellow, 1 double post.4. A half yellow (the one just attached) over a full

yellow, 2 double posts, in the middle.5. A half white over a full blue, 1 double post.6. A half white over a full blue, 1 double post, other

side7. One full green over two half white, 1 double post,

empty middle.8. A full white over a full green, 2 double posts.9. A full white over a full green, 2 double posts,

other side.

List of Instructions to Make the Lego ObjectList of Instructions to Make the Lego Object

Page 13: Introduction, Computers work by following a series of steps. Computers work by following a series of steps. These steps organize objects (set of variables)

Build the Lego piece based on the Build the Lego piece based on the instructions instructions that follow. Make sure to use the piece that is indicated and the connection described.

Pyramid:Pyramid:

Base:Base:1. Full green over full black, 1 double post, inline2. Full green (from step 1) over full black (new), 1

double post, inline3. Full yellow (new) over full black (from step 2), 1

double post, inline4. Full yellow (from step 3) over full black (new), 1

double post, inline5. Full blue (new) over full black (from step 4), 1 double

post, inline6. Full blue (from step 5) over full black (new), 1 double

post, inline

Page 14: Introduction, Computers work by following a series of steps. Computers work by following a series of steps. These steps organize objects (set of variables)

Pyramid Cont.:Pyramid Cont.:

Top:Top:

7. Full red (new) over full green (from step 1) and full yellow (from step 3), 1 double post on each (green and yellow) - empty middle

8. Full white (new) over full yellow (from step 3) and full blues (from step 5), 1 double post on each (yellow and blue) - empty middle

9. Full black (new) over full red (from step 7) and full white (from step 8), 1 double post on each (red and white) - empty middle

You should be done, let your instructor take a look at your Lego build.

Page 15: Introduction, Computers work by following a series of steps. Computers work by following a series of steps. These steps organize objects (set of variables)

Did yours come out something like ,Did yours come out something like ,

Page 16: Introduction, Computers work by following a series of steps. Computers work by following a series of steps. These steps organize objects (set of variables)

Build the Lego piece based on the Build the Lego piece based on the instructions instructions that follow. Make sure to use the piece that is indicated and the connection described.

Part 1 - Base:Part 1 - Base:

1. One half yellow over 4 full black, 1 single poll, holding the corner of the full pieces together

For the next set of instruction let the instructor know you are ready.

Page 17: Introduction, Computers work by following a series of steps. Computers work by following a series of steps. These steps organize objects (set of variables)

Build the Lego piece based on the Build the Lego piece based on the instructions instructions that follow. Make sure to use the piece that is indicated and the connection described.

Part 2 - Trunk:Part 2 - Trunk:

2. A half white (new) over a half yellow (from step 1), 2 double poles

3. A half yellow (new) over a half white (from step 2), 2 double poles

4. A half white (new) over a half yellow (from step 3), 2 double poles

5. A half yellow (new) over a half white (from step 4), 2 double poles

6. A half white (new) over a half yellow (from step 5), 2 double poles

For the next set of instruction let the instructor know you are ready.

Page 18: Introduction, Computers work by following a series of steps. Computers work by following a series of steps. These steps organize objects (set of variables)

Build the Lego piece based on the Build the Lego piece based on the instructions instructions that follow. Make sure to use the piece that is indicated and the connection described.

Part 3 - Treetop:Part 3 - Treetop:

7. A full green (new) over a half white (from step 6), 2 double poles, in middle

8. A half green (new) over a full green (from step 7), 1 single pole

9. A half lime (new) over a full green (from step 7), 1 single pole, next to the half green in step 8

10.A half green (new) over a full green (from step 7), 1 double pole, in the middle, next to the half lime in step 9

11.A half grey (new) over a full green (from step 7), 1 double pole, at the end of the full green, inline

12.A half lime (new) over a half green (from step 10) and half grey (from step 11), 1 single pole with half green and 1 double pole with half grey

For the next set of instruction let the instructor know you are ready.

Page 19: Introduction, Computers work by following a series of steps. Computers work by following a series of steps. These steps organize objects (set of variables)

Build the Lego piece based on the instructions Build the Lego piece based on the instructions that follow. Make sure to use the piece that is indicated and the connection described.

Part 3 – Treetop Cont.:Part 3 – Treetop Cont.:

13. A half grey (from step 11) over a half grey (new), 1 single pole

14. A grey (from step 11) over a half orange (new), 1 single pole, next to previous grey

15. A full green (from step 7) over half orange (new), 1 double pole, opposite side of last half orange

You should be done, let your instructor take a look at your Lego build.

Page 20: Introduction, Computers work by following a series of steps. Computers work by following a series of steps. These steps organize objects (set of variables)

Did yours come out something like ,Did yours come out something like ,

Page 21: Introduction, Computers work by following a series of steps. Computers work by following a series of steps. These steps organize objects (set of variables)

Write the instructionsWrite the instructions, required , required for you to build the Lego piece for you to build the Lego piece below.below.

1. Remember to identify Lego pieces as either full or full or half half and then the colorcolor.

2. State which Lego is overover the other Lego.

3. The number post(s) reached, 1, 2, 3 or 41, 2, 3 or 4.

4. The type of connection single post single post or double double postpost.

5. Clarifying comments

Page 22: Introduction, Computers work by following a series of steps. Computers work by following a series of steps. These steps organize objects (set of variables)

Write the instructionsWrite the instructions, required , required for you to build the Lego piece for you to build the Lego piece below.below.

1. Remember to identify Lego pieces as either full or full or half half and then the colorcolor.

2. State which Lego is overover the other Lego.

3. The number post(s) reached, 1, 2, 3 or 41, 2, 3 or 4.

4. The type of connection single post single post or double double postpost.

5. Clarifying comments

Page 23: Introduction, Computers work by following a series of steps. Computers work by following a series of steps. These steps organize objects (set of variables)

Questions:Questions:1.Should your list of instructions be the same as everyone elses in the class?

YesYes oror NoNo

2.Explain why your answer is correct (question 1).

3.Using our format of instructions, can two people follow the instructions correctly and not have the same Lego construction (shape) in the end?

YesYes oror NoNo

4.Give an example of an instruction that can be followed correctly two different ways.

5.How could the format of the instructions be changed in order to fix this problem?