Multiple choice technology programming languages

When do you need to use an array?

  1. To create a mutable string

  2. To store a single character

  3. To store multiple items of the same type

  4. none

Reveal answer Fill a bubble to check yourself
C Correct answer
Explanation

An array is a data structure used to store a fixed-size, sequential collection of multiple items of the same data type. A single character is stored in a primitive char variable, and mutable strings are handled by classes like StringBuilder or StringBuffer in Java.