logo

AQA A-Level Computer Science practice

What is one advantage of using a named constant instead of repeatedly writing the same literal value?

Try the question first, then check the answer and practise the same topic again.

At a glance

MCQ

Type

practice

Style

Topic

Programming

Exam-style question

Try this first

What is one advantage of using a named constant instead of repeatedly writing the same literal value?.

  1. A.It makes the value impossible for the program to use
  2. B.It can make the program easier to understand and update
  3. C.It guarantees that the program contains no errors
  4. D.It means that all variables become constants

Answer and explanation

Concise answer

It can make the program easier to understand and update

Why this is correct

A meaningful name communicates the purpose of the value. If the value needs changing, it can be changed in one named declaration rather than in multiple places.

Use the concise answer above for a quick check, then reveal the full model answer and detailed explanation.

Common mistake

No common mistake is linked to this question yet.

Related flashcards

No flashcards are published for this page yet.

Related practice questions