need help with pascal programming

Solution
Whilst that is good advice, there are times when it can be useful to end a program prematurely. The lack of exception handling in Pascal means that this is sometimes better than constructing a convoluted structure. In C this is handled by the "return" statement; the nearest equivalent in Pascal is the "halt" statement.

Ijack

Distinguished
Whilst that is good advice, there are times when it can be useful to end a program prematurely. The lack of exception handling in Pascal means that this is sometimes better than constructing a convoluted structure. In C this is handled by the "return" statement; the nearest equivalent in Pascal is the "halt" statement.
 
Solution