Question
Hi, I am a bit puzzled. i need to put the list of instructions for 1-9 in the blank spaces. Each of the following four
Hi, I am a bit puzzled. i need to put the list of instructions for 1-9 in the blank spaces.
Each of the following four problems consists of a mixed up set of instructions which, when put in proper order, step by step method of performing a task. Can you put the instructions in the correct order by writing the correct step number in each blank?
1. A procedure is needed to change all the traffic lights in a small town for one cycle only. Lights that are red must be changed green and lights that are green must be changed to red. (no yellow lights and there are no lights that aren't working). Assume that you have a street map that shows the location of all the lights. The "go to" statements will help you avoid ending up all the lights the same color.
____ Find a light on your map that is not marked "done" and check whether it is red or green.
____ turn the light red.
____If there are lights on your map not marked "done", the go to the next step; otherwise, go to step ____.
____ if the light is green, then go to the next step; otherise go to step ____
____ on your map, make the light you just changed as "done."
____ go to step ____.
____ go to step ____.
__9_ End.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started