Which one of the following is the correct definition for initializing data in a two-dimensional array of three rows and two columns?
A) int[][] arr =
{
{ 1, 1, 1 },
{ 2, 2, 2 },
};
B) int[][] arr =
{
{ 1, 1 },
{ 2, 2 },
{ 3, 3 }
};
C) int[][] arr =
{
{ 1, 1 }
{ 2, 2 }
{ 3, 3 }
};
D) int[][] arr =
{
{ 1, 1, 1 }
{ 2, 2, 2 }
{ 3, 3, 3 }
};
Correct Answer:
Verified
Q23: Consider the following code snippet:
String[] data =
Q26: Consider the following code snippet:
String[] data =
Q50: Consider the following code snippet. Which statement
Q51: Which one of the following is the
Q52: Why is the following method header invalid?
Q53: Consider the following code snippet:
Int[][] numarray =
{
{
Q56: Which one of the following statements is
Q57: Consider the following code snippet: String[] data
Q58: What is the output of the following
Q59: Consider the following code snippet:
Int[][] arr =
{
{
Unlock this Answer For Free Now!
View this answer and more for free by performing one of the following actions
Scan the QR code to install the App and get 2 free unlocks
Unlock quizzes for free by uploading documents