Jump to content
Main menu
Main menu
move to sidebar
hide
Navigation
Main page
Recent changes
Random page
Help about MediaWiki
Special pages
Science Theatre
Search
Search
Appearance
Create account
Log in
Personal tools
Not logged in
Talk
Contributions
Create account
Log in
Editing
Robo Sandwich Maker
(section)
Page
Discussion
English
Read
Edit
View history
Tools
Tools
move to sidebar
hide
Actions
Read
Edit
View history
General
What links here
Related changes
Page information
Appearance
move to sidebar
hide
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
== Why This Works == In basic computing, a computer takes a ''Command'', or instruction, and does a task based on that command. These commands have to be clear and concise, otherwise the computer might get confused and perform the wrong tasks. Modern computers have built in safety functions to prevent these irregular commands from running, and to keep the computer operating. This is similar to the "DOES NOT COMPUTE" response given when a step was not clear enough. Other times, instead of trying to follow the command and doing something wrong, the computer will say that it does not understand and ask for the command to be clarified. This is similar to the "NEEDS CLARIFICATION" response given later on. When the class worked together to make a list of commands for making a sandwich, they made a program for the Robo Sandwich Maker to use. ''Programs'' are long lists of commands that connect to each other, and are recognized as all being a part of the same process. The computer recognizes that they are connected, and will run them all together. Even if some of the commands in a program are not as precise, the computer will recognize that the command is within the rest of the program, and run it according to how it is intended. The list below can help show how a command can be clarified, and how to help the audience write a clearer set of commands for a program. {| class="wikitable" style="color:black; background-color:#ddd; text-align: left; margin-right: auto" | '''Initial Command(s)''' | '''Issue''' | '''Rewritten Command(s)''' | '''Notes''' |- | <pre>Put bread on plate </pre> | *"Bread" can refer to the whole loaf | <pre>Put a slice of bread on plate </pre> |- |<pre>Add lettuce</pre> | * Unsure on where to add lettuce * "Lettuce" can refer to whole lettuce head/package *"Sandwich" is undefined, since we haven't made it yet. |<pre>Put one leaf of lettuce on slice of bread on plate </pre> |- |<pre>Open pack of ham Put ham on sandwich close pack of ham </pre> | * "Ham" can refer to whole package * No number of ham slices specified *"Sandwich" is undefined | <pre>Open pack of ham Pull out three slices of ham Put slices on bread on plate Close pack of ham</pre> | In step 3 we don't restate what the slices are, since the command string, or program, is for "Ham". |- | <pre>Open ketchup bottle Add one squirt to sandwich Open mustard bottle Add one squirt to the sandwich Open relish jar Add one spoonful to the sandwich</pre> | * No descriptor on "squirt" (big/small) * Ketchup isn't closed, so it is still in use * "Squirt" applied to mustard '''and''' ketchup * Mustard isn't closed, so it is still in use * "Spoonful" applied to relish '''and''' mustard '''and''' ketchup *"Sandwich" is undefined |<pre>Open ketchup bottle Add one small squirt to ham slice on bread Close ketchup bottle Open mustard bottle Add one small squirt to ham slice on bread Close mustard bottle Open relish jar Add one spoonful to ham slice on bread Close relish jar</pre> | By closing the bottles, we close the previous command strings and don't add extra ketchup & mustard. Note that for the command strings, we don't need to specify the ingredient being added. |}
Summary:
Please note that all contributions to Science Theatre are considered to be released under the Creative Commons Public Domain Dedication (see
Science Theatre:Copyrights
for details). If you do not want your writing to be edited mercilessly and redistributed at will, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource.
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Search
Search
Editing
Robo Sandwich Maker
(section)
Add topic