Saying Precisely What You Mean
In order to be compiled correctly into machine language instructions, programs need to be written very precisely.
As a programmer, your job is to think about the big picture of what you want the program to do, and then break it down into bite-size steps that can be accomplished by the computer without errors. For example, if you wanted to ask a robot to go downstairs and get you a sandwich, you might start your instructions like this:
- Rotate head toward stairs.
- Use visual sensors to look for obstacles.
- If an obstacle is found, determine what it is.
- If the obstacle ...