Ask Question
6 February, 07:06

Which of the following is a correct method header for receiving a two-dimensional array as an argument? A. public static void passArray (int[1,2]) B. public static void passArray (int [ ][ ]) C. public static void passArray (int[1],[2]) D. public static void passArray (in[ ], int[ ])

+5
Answers (1)
  1. 6 February, 10:23
    0
    The correct option for this question is "B".

    Explanation:

    An Array is a collection of the homogenous (same type) elements. In the programming language, the correct way to pass two-dimensional array in function as an argument is option "B" and other options are not correct that can be described as:

    In option, A It is a one-dimensional array but it is not a correct way to pass array in an argument like this. In option, C It is a two-dimensional array but in this array, we do not pass any number. In option, D it is not a two-dimensional array.

    That's why the answer to this question is option "B".
Know the Answer?
Not Sure About the Answer?
Get an answer to your question ✅ “Which of the following is a correct method header for receiving a two-dimensional array as an argument? A. public static void passArray ...” in 📙 Computers & Technology if there is no answer or all answers are wrong, use a search bar and try to find the answer among similar questions.
Search for Other Answers