MCQ Practice Single Best Answer Topic: ICSE Computer Application - Class X - Selection Examination - 2024-25 - MCQ - CALCUTTA PUBLIC SCHOOL

Q The second last element of an array of size 100 has index:

Question ID
#23880
Subchapter
ICSE Computer Application - Class X - Selection Examination - 2024-25 - MCQ - CALCUTTA PUBLIC SCHOOL
Action
Choose one option below

Choose Your Answer

Click an option to check whether your answer is correct.

  • A 97
  • B 98
  • C 99
  • D 100
Correct Answer: B

Explanation

Explanation:

 

Array indexing in Java starts from 0.

For an array of size 100, the last element has index 99.

The second last element has index 98.

Share This Question

Share this MCQ with your friends or study group.