About Me

header ads

PROGRAM DEBUGGING

PROGRAM DEBUGGING
Detecting and removing errors from program is called program debugging.
There are 4 basic types of errors.

1)SYNTAX ERRORS:-

Every programming language has its own set of rules . And the errors which violate such rules are referred to as syntax errors.
Syntax errors are detected by the compiler during compile time.
Following are the examples of syntax errors .
1)
int  emp-salary
Missing semicolon error i.e. syntax error
2)
printf(hey);
Double inverted commas missing i.e. Syntax Error 

2) RUN TIME ERRORS :-

The errors which occurs during the run time of a program are refers to as run time errors .
Generally run time errors occurs when there is any mismatch of basic data type or make an eligible reference and so on.


3) LOGICAL ERRORS :-

The error which are related to the logic of the program are refereed so as logical errors , logical errors occurs due to wrong jumping , fail to satisfy a particular condition and any incorrect order of evaluation of statements .
Logical errors are typical to trace because these cannot be detected at compile time or run time.
Example a/0;

4) LATENT ERRORS :-
The errors that comes or occurs during the execution of the program
when we enter a special value are called latent errors . Latent errors can be detected only by using all possible combination of test data