Right Click to Search

Wednesday, December 30, 2024

Multidimensional Array in C Programming


Multidimensional Array : 
  • has more than one Subscript Variables 
  • Consider 2-D array - It has two Subscript Variables
  • One Subscript variable denotes row another denotes column.

 
Declaration Example :
int a[3][3];
Meaning :
  • Matrix is having 3 rows ( i takes value from 0 to 2 )
  • Matrix is having 3 Columns ( j takes value from 0 to 2 )
  • As shown in above diagram 3x3 matrix will have 9 blocks having 3 rows & 3 columns 
  • Let the name of 2-D array is 'a' then each block is identified by the row & column number
  • Take look at Element A[2][1] which is block placed in 2nd row and first column
  • Here numbering starts from 0 so 3 rows will be counted as 0th,1st,2nd row
Bookmark & Share

Tags / Keywords : |

Stumble
Delicious
Technorati
Twitter
Facebook

1 Comment:

prafull said...

thanx for the help ..r''ly usefyul

Post a Comment

Your Feedback :This is Growing Site and Your Feedback is important for Us to improve the Site performance & Quality of Content.Feel Free to contact and Please Provide Name & Contact Email

 

Learn C Programming Copyright © 2010 LKart Theme is Designed by Lasantha, Free Blogger Templates