Ask Question

What does the following statement do? double[] array1 = new double[10]; A. Declares array1 to be a reference to an array of double values B. Creates an instance of an array of 10 double values C. Will allow valid subscripts in the range of 0 - 9 D. All of the above

+5
Answers (1)
  1. 8 November, 14:09
    0
    The answer is "Option D".

    Explanation:

    In the given code an array that is "array1" is declared that stores double value because its data type is double. This array stores 10 element, that is equal, and between 0 to 9, because array indexing always starts from 0. In the given array declaration code all options are correct, that can be described as follows:

    In option A, It is correct, because all element stores double value. In option B, It is correct, because the size of the array is 10. In option C, It is also correct, because it ranges between 0 to 9.
Know the Answer?
Not Sure About the Answer?
Find an answer to your question 👍 “What does the following statement do? double[] array1 = new double[10]; A. Declares array1 to be a reference to an array of double values ...” in 📗 Computers & Technology if the answers seem to be not correct or there’s no answer. Try a smart search to find answers to similar questions.
Search for Other Answers