A set of steps that could be set as a function is brushing your teeth.
Pick up tooth brush
check it is clean.
If not clean tooth brush. start set 2 again
Pick up tooth paste
open lid of tooth paste
Squeeze small amount of toothpaste on to tooth brush head.
Replace tooth paste lid and put toothpaste down
put toothbrush under tap spout
Turn on tap
wet toothbrush head
turn off tap
put tooth brush head in mouth
Move toothbrush head vigorously against teeth
Stop moving tooth brush
remove toothbrush from mouth.
This could continue in as much detail as you want to any point.
The key point is that machines only do what they are instructed and debugging is the process of running the function to make sure the task is done to a point that is expected and successfully
You must log in to post a comment.