Q. If a negative value is used for an array index, ____.

  • (A) a NumberFormatException is thrown
  • (B) the program terminates immediately
  • (C) the last index of the array is automatically accessed instead
  • (D) an IndexOutOfBoundsException is thrown
πŸ’¬ Discuss
βœ… Correct Answer: (D) an IndexOutOfBoundsException is thrown

You must be Logged in to update hint/solution

πŸ’¬ Discussion


πŸ“Š Question Analytics

πŸ‘οΈ
188
Total Visits
πŸ“½οΈ
3 y ago
Published
πŸŽ–οΈ
Mr. Dubey
Publisher
πŸ“ˆ
91%
Success Rate