Debugging is a process of letting your program run until it does something that you did not expect it to do. After finding a bug, you modify the program so that it does not encounter the bug when the program is in the exact machine state that initially produced the bug. This is accomplished by a combination of back-tracking, intuition, and trial and error. The major obstacle to effective debugging is that removing one bug can introduce new bugs into your program. You should consider general debugging tips as well as some debugging techniques specific to PL/I.
Consider the following tips when debugging your programs:
For example, the undesired change in the state of program execution might be the unintended assignment of the decimal value "100" to the character variable "z". In this case, you might find that the source code has an error that assigns the wrong variable in an assignment statement.