Multidimensional array | Sololearn: Learn to code for FREE!

0

Multidimensional array

how to find the value couldn't understand the topic plz explain

7/28/2017 10:04:53 AM

Maharajan

2 Answers

New Answer

+2

https://www.sololearn.com/discuss/494391/?ref=app

+1

A Multidimensional Array is an array containing other arrays. The simplest kind is the two dimensional array, it is an array containing arrays which do not contain other arrays. int [][] multi = new int [][]{ {3, 4, 5}, {6,7,8} }; If you want to access the array, you just have to use the indexes as in normal arrays. Let's say we want to access the 4: multi [0][1] The first brackets stand for the index of the first array which contains number 4. The second brackets stand for the index of four, you handle it like in a normal array. First you access the array itself, then it's components.