0
What is an array?
x[5]
8 Antworten
+ 3
An array is a collection of elements, each identified by at least one array index or key
+ 3
You can see it like a furniture with unlimited size where you can store datas (box) and datas (box) inside datas (box).
+ 3
An array is used to store a collection of data, but it may be useful to think of an array as a collection of variables that are all of the same type.
Instead of declaring multiple variables and storing individual values, you can declare a single array to store all the values.
+ 2
- array declaration ( type name[elements]; )
int foo[5];
- array initializer ( elements is optional )
int foo[5] = { 5, 3, 2, 1, 4 };
- get/set ( index from 0 to elements - 1 )
int v = foo[0];
foo[4] = 1;
+ 2
Collection of similar objects... 😂 😂 😂
+ 1
thnx
0
Can anyone give me a simple example....
0
need upvode