logo

Cambridge IGCSE Computer Science practice

Which of the following correctly accesses the first element of a 1D array named 'arr'?

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

At a glance

MCQ

Type

cambridge_mcq

Style

Topic

Arrays

Exam-style question

Try this first

Which of the following correctly accesses the first element of a 1D array named 'arr'?.

  1. A.arr[0]
  2. B.arr[1]
  3. C.arr[2]
  4. D.arr[first]

Answer and explanation

Concise answer

arr[0]

Why this is correct

Array indexing starts at 0, so the first element is at index 0.

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

Flashcard 1 of 6

Press Space to flip, arrows to move

Related practice questions