Java Array getLength() MethodThe getLength() method of Array class returns the length of the specified array object, as an int. SyntaxParameterarray - the array index - the index Returnsthe length of the array ThrowIllegalArgumentException Example 1Test it NowOutput: 890 980 [890, 980] Example 2Test it NowOutput: Array length :: 2 Next TopicJava Array Class |
We provides tutorials and interview questions of all technology like java tutorial, android, java frameworks
G-13, 2nd Floor, Sec-3, Noida, UP, 201301, India