Welcome to Westonci.ca, your one-stop destination for finding answers to all your questions. Join our expert community now! Join our Q&A platform to connect with experts dedicated to providing accurate answers to your questions in various fields. Our platform offers a seamless experience for finding reliable answers from a network of knowledgeable professionals.

When declaring the data type for a multidimensional array of strings, which statement would be most appropriate?

Sagot :

Answer:

This question required option (See Explanation)

Explanation:

Required

How to declare 2D array

Using Java as a programming language of reference, the syntax to declare a 2D array is:

Data-Type [][] Array-Name = new Data-Type[Rows][Column]

From the question, the data type is String. So, the syntax becomes

String [][] Array-Name = new String[Rows][Column]

Assume the array name is: myArray; The above becomes

String [][] myArray= new String[Rows][Column]

I will not assume values for Rows and Column, but it is worth saying that Rows and Columns are positive integers greater than 1 to make the array a 2 D array