Types of Arrays in C - C Programming Tutorial 68

preview_player
Показать описание
Notes for You:: Types of Arrays in C - C Programming Tutorial 68

Arrays are mainly classified in to 2 types:
- One dimensional array.
- Multi-dimensional arrays.

Multi-dimensional arrays are again classified in to:
- 2-dimensional,
- 3-dimensional
- and so on an n-dimensional array.

1-dimensional array:
- While accessing each element in an array; if it requires only one index or subscript such an array is called 1-dimensional array.
Example: arrayName[index]

Where:
- index can be a row index or column index.
- Because 1D array is used to store list of values arranged in a row or column i.e. set of values arranged in either x axis or y axis.

2-dimensional array:
- While accessing each element in an array; if it requires two indexes or subscripts such an array is called 2-dimensional array.
Example: arrayName[index1][index2]

Where:
- index1 must be a row index and index2 must be column index
- Because 2D arrays are used to store table of values arranged in rows and columns i.e. set of values arranged in both x and y axis

3-dimensional array:
- While accessing each element in an array; if it requires three indexesor subscriptssuch an array is called 3-dimensional array.
Example: arrayName[index1][index2][index3]

Where:
- index1 must be a x index, index2 must be y index &index3 must be z index
- Because 3D arrays are used to store set of values arranged in x, y and z axis.

And so on …

n-dimensional array:
- While accessing each element in an array; if it requires n indexes or subscripts such an array is called n-dimensional array.
Ex: arrayName[index1][index2][index3]….[indexn]

=========================================

Follow the link for next video:

Follow the link for previous video:

=========================================

C Programming Tutorials Playlist:

=========================================
Watch My Other Useful Tutorials:-

Computer Programming Fundamentals Playlist:-

C Practical LAB Exercises Playlist:-

C++ Tutorials Playlist:

=========================================

► Subscribe to our YouTube channel:

► Visit our Website:

=========================================
Hash Tags:-
#ChidresTechTutorials #CProgramming #CProgrammingTutorial
Рекомендации по теме
Комментарии
Автор

Answer the following questions: Let's see who gives the best answer
1. What is one dimensional array in C ?
2. What is two dimensional array in C ?
3. What is three dimensional array in C ?

ChidresTechTutorials
visit shbcf.ru