### Matrix in Java

Creating a matrix

In this example you will learn about array and matrix. An array is the collection of same data type values. If we create a variable of integer type then, the array of int can only store the int values. It can't store other than int data type.

In this example you will learn about array and matrix. An array is the collection of same data type values. If we create a variable of integer type then, the array of int can only store the int values. It can't store other than int data type.

**Matrix:**A matrix is a collection of data in rows and columns format. In this program we are going to implement a matrix. To make a program over the two dimensional array,irst of all we have to declare class named as