On days that you have to go to school, your mother and father are behind you in the morning, asking you to wake up, while you keep saying ‘5 more minutes!’ until you realize it is late and you don’t have time to take bath. So, you decide to just wash your face, brush your teeth, and get dressed. To get dressed, you follow a particular sequence of steps, like the one given below:
Here, as you can see, you followed a set of instructions to complete a task, which is getting dressed (though hastily, and without taking a bath!).
Now, you know that to properly get dressed, you need to follow the order; you won’t wear a fresh pair of undergarments before taking off the previous ones, nor would you put on the uniform first and then wear undergarments (unless you’re Clark Kent!).
Similarly, you must write the program in a particular order so that the computer does the task given to it correctly, and we get the result that we expect.