Preparing and Running A C Program


The overall program strategy should be completely drawn before programming actually begins. This is how the programmer can concentrate on the general programming logic. This process may be repeated several times. Once all the programming strategy has been clearly established than the syntactic details should be considered.

Program Planning:

Before starting with C, we should understand what is program planning and why it is important. As before building a house you consult an architect to draw a basic model of a house, similarly it is essential for every programmer to plan a program and its structure before actually making it.
           
Most of the high level computer languages help in designing the computer programs using which you perform complex tasks or even control your computer. Each line of code performs a particular task so it is very essential to arrange the various lines of code in a program properly to perform a complex task. While developing a program the following steps need to be followed:

  • Understanding the problem: You must have clear idea of what you want to do. You should be aware of type of inputs you expect and how inputs is to be processed and what kind of output is required.
  • Detailed Design: You must divide the program into set of well-defined self contained and manageable chunks. Each chunk should be able to connect with other chunk although they may relatively work independent of the program.
Programming planning helps in arranging various instructions to be used in a program. A properly planned program is easier to design. Once the program is planned properly is earlier to implement and test it. Tools that are used to designing a very well planned program:
  • Flowcharts
  • Decision Tables
  • Pseudo code

Previous                                                                                    Next

Powered by Blogger.