Topic
Algorithm keying
Instructions
This project provides you with the opportunity to examine algorithms, identify the inaccuracies in the algorithms, and finally, to modify the algorithms with the correct details. Your next step will be to write an algorithm that includes the three control structures (sequence, selection, and repetition). First, explain the purpose of the algorithm by providing a brief description for the task being performed. Then, list the details of the algorithm. Remember to include all three control structures (sequence, selection, and repetition).
Select ONE of the following tasks as the basis for completing your algorithm:
- Changing a television channel by using a remote control
- Using a sponge to wash a car
- Walking up a set of stairs
Open the attached Unit I template file for this project. This document include two algorithms you will review, identify the inaccuracies, and insert the corrections. Additionally, there is a space for you to add the algorithm you will write. Complete your work on this template, save the document.
Chapter 2: Exercises 1, 2, & 3
Complete Exercises 1, 2, and 3 in the Exercises section at the end of Chapter 2 on page 31 (see attached). Check your answers for Exercises 1 and 2 by referring to Appendix B (see attached). The answer for Exercise 3 is not in Appendix B, so your grade will be heavily based on how you complete it.
Answer preview
Algorithm 1:
repeat (2 times)
walk forward 1 step,
end repeat
if a flower is present, do this:
pick up the flower
end if
repeat (2 times)
turn left 45 degrees
end repeat
Word count: 198