You are on page 1of 2

Stella Connaughton

9.12.15

Algorithm for Making a Peanut Butter & Jelly Sandwich

Commands robot understands

1.

Open: remove lid from jar. Works on jelly jar and peanut butter jar

2.

Close: screws lid back on jar. Works on jelly jar and peanut butter jar

3.

pick up: takes object off of table and holds it: Works on all objects

4.

put down: places object on table. Works on all objects

5.

scoop: collect an object in a swift movement. Works on knife

6.

spread: use knife with substance on it to distribute substance. Works on knife.

7.

walk: move from one location to another

Environment

Main ingredients (jar of peanut butter, jar of jelly, knife, plate, bread slices) located on a table. Peanut butter jar is
closed and full. Jelly jar is closed and full. Both jars are located at the center of the table. Knife is located at the end of
table. Two slices of bread is located in the middle, placed under the jars, on a plate, separate and lying flat.

1.

Walk to the middle of the table

2.

Pick up peanut butter jar

3.

Open peanut butter jar

4.

Put down peanut butter jar

Stella Connaughton
9.12.15
5.

Walk to end of table where knife is located

6.

Pick up knife

7.

Scoop peanut butter with knife

8.

Walk to center of table where bread is located

9.

Spread peanut butter on one side of one slice of bread, peanut butter side facing up

10. Put down knife

11. Pick up jelly jar

12. Open jelly jar

13. Put down jelly jar

14. Pick up knife

15. Scoop jelly with knife

16. Spread jelly on one side of the slice of bread with no peanut butter, jelly side facing up

17. Put down knife

18. Pick up slice of bread with jelly on one side

19. Put down slice of bread with jelly on one side on top of slice of bread with peanut butter, jelly side facing
opposite peanut butter side

You might also like