I am using a multi-dimensional array to store the total amount of product sold (products range 1 to 5) by a particular salesperson (1 to 4 salespersons).
T arranged
Lets say you have a two dimensional array as
int[][] salesData={{13, 23, 45, 67, 56},
{43, 65, 76, 89, 90},
{43, 45, 76, 98, 90},
{34, 56, 76, 43, 87}};
so it is a 4*5 matrix
int[0] represents the the 1st row i.e the {13, 23, 45, 67, 56} if you need the value in individual cell you need to iterate 2 for each loop like
for (int[] rowData: salesData){
for(int cellData: rowData)
{
System.out.printn("the indiviual data is" +cellData);
}
}