OCR GCSE Computer Science · J277
Paper 2
Revise: Variables, Constants, and OperatorsA constant is a named value that remains fixed while the program runs. It is useful for values such as a tax rate, a ticket price or an approximation of pi. Giving the value a name makes its purpose clear and lets the programmer refer to it throughout the program.
- Revise: Using Subprograms
A named value intended to remain unchanged while a program runs. A constant can have local or global scope.