declare constants
Posted:
Fri Sep 10, 2010 12:20 am
by swapna namburu
How to declare constants in cobol.
thats mean we can't change that value through out the program.
Re: declare constants
Posted:
Fri Sep 10, 2010 12:24 am
by dick scherrer
Hello,
Anything that can be "declared" can be modified. . .
It is the responsibility of the programmer to ensure that values that are to remain constant are not modified.
Re: declare constants
Posted:
Fri Sep 10, 2010 12:28 am
by Robert Sample
COBOL has a few figurative constants (such as ZERO, SPACE, HIGH-VALUES, LOW-VALUES) however it does not have the ability to declare constants as non-changeable values per se. What are you wanting to do, specifically? Perhaps there's a way to achieve your goal without requiring constants.