Organization of Program
A set of instructions used by a computer to solve a problem is called a program. These instructions are generally divided into three parts, namely, input, processing and output. That is, how many instructions are used for inputting data, how many instructions are used for processing and how many instructions are used for displaying output. The relationship between these instructions is shown below in the diagram:
Instructions to input
↓
Instructions for data processing
↓
command to provide output
Program development steps :
There are several sequential steps to be followed in the process of writing a program and executing it on a computer to perform various tasks. Each step is discussed in detail below:
(1) Investigation
(2) Problem analysis (Problem analysis)
(3) Program design
(4) Program coding (Program coding)
(5) Program testing, debugging and implementation (Program testing, debugging and implementation)
(6) Program maintenance
1. Finding information: Creating a complete and simple description of the problem that the program is to be written to solve. Collect all kinds of information related to the problem. Like- knowing the current procedure, knowing the total time to solve the problem etc. The programmer can be well informed about the needs and problems of the user for whom the program is to be written.
2. Problem Analysis: After defining the problem, data about the problem is collected and analyzed. After being well informed about the problem, it is necessary to determine whether the problem can be solved using a computer at all, or if it is possible, it is convenient. Determining the structure of the problem, determining the data flow and destination, as well as determining the computer memory. In this step, four issues are determined. namely- (1) input identification (2) output identification (3) memory determination and (4) preparing a structured description of the problem.
3. Program Design: In this step, a flowchart with a complete structure method and convenient algorithm should be created to solve the problem. Depending on the type of problem and the potential for new problems to emerge, the program may need to be modified. The program may suffer from various problems if used for a long time. The program should be freed from these problems. The program design part is where the pseudocode of the program is created.
4. Program Coding: After creating the program algorithm and flowchart, the actual program has to be written. The programming language has to be chosen based on the type of program. Different languages are suitable for different problems such as Cobble is very useful for business use. FORTRAN is useful for scientific and engineering-related problems. Writing programs using specific programming languages is called program coding. There are usually several programming languages for coding programs; Like QBASIC, C, PASCAL etc. Due to the widespread use of microcomputers, the Q BASIC programming language became very popular. It is convenient to do the coding first on a coding form or on paper rather than writing it directly on the computer.
5. Program Testing, Debugging and Implementation: The program from the source has to be converted into machine language by a translator program. Through this transformation, programming problems and errors are detected during transmission to the destination, called program bugs. If a bug is found in the program, the programmer tries to fix it. The program must be accurate to flow from the source to the destination. Besides, the program is not properly converted into mechanical language due to logic errors or blow up. Debugging is the process of debugging a program. The program does not run for the slightest, such as a comma or semicolon or a spelling mistake. So the program has to be debugged through a dry run or experimental use. The program has to be implemented without errors.
After writing the program some errors are caught while testing. A program error is called a program bug. During program testing, all the bugs are fixed. Correcting program errors is called Program Debugging. There are three types of program bugs. namely-
1. Syntax bug
2. Logical bug
3. Data bug.
Syntax Bug: Every programming language has its own grammar. The program writer has to write the program according to all these grammar while writing the program. A syntax bug is a grammatical error in the generated program. Grammatical mistakes during program writing cause problems in program execution. Then the programmer has to complete the task of syntax debugging.
Logical Bug: In some programs, the programmer makes mistakes in applying logic. Such a fallacy is called a logical bag. If there is a logical bug in the program, the result will not be correct. For example, if the program to find the largest number out of three numbers results in a small number, then it must be understood that there is a mistake in the logic. In this case, the programmer has to do logical debugging.
Data Bugs: Programmers often make mistakes in inputting data. This type of program error is called a data bug. For example if students' names are spelled wrong or wrong data is inputted in the marks obtained then the result will be wrong. So the programmer has to do data debugging.
6. Program Maintenance: Program maintenance includes the work of improving the program for future needs and correction of errors, maintenance etc. Program maintenance is important to keep the program virus free. Program maintenance is also important to make old programs compatible with modern computers. Currently, various business organizations have been formed to do this very expensive and important work.
Comments
Post a Comment