elibraryportal Logo

2D Array or Tow Dimensional Array in C

Two dimensional (2D) array is also known as matrix. Where matrix can be represented as a table of rows and columns.

Syntax

Example


2D Array Initialization

Full Example

Output

Enter value for disp[0][0]:1
Enter value for disp[0][1]:2
Enter value for disp[0][2]:3
Enter value for disp[1][0]:4
Enter value for disp[1][1]:5
Enter value for disp[1][2]:6
Two Dimensional array elements:
1 2 3 
4 5 6 
Next Topic