0% found this document useful (0 votes)
5 views1 page

Understanding Array Data Structures

Arrays are used to store multiple values of the same data type in a single variable, with indexing starting from 0. They have a fixed length and can override values when duplicates are assigned to the same index. However, arrays do not support dissimilar data types and can lead to high memory wastage.

Uploaded by

K.Ramesh Babu
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
5 views1 page

Understanding Array Data Structures

Arrays are used to store multiple values of the same data type in a single variable, with indexing starting from 0. They have a fixed length and can override values when duplicates are assigned to the same index. However, arrays do not support dissimilar data types and can lead to high memory wastage.

Uploaded by

K.Ramesh Babu
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd

Array:

=========
Storing multiple values in a single variable

Features:
=========
1. It supports similar data type
2. It is index based
3. Index starts from 0-(n-1)--------->n is ur length

Syntax :

=========

int[] a = new int[5];


or
int a[] = new int[5];

Note:
=======
When we assign a duplicate value in the same index it will
override the value.

Disadvantages:
==============
1. It will not support disimilar data type.
2. The length is fixed.
3. It has high memory wastage.

You might also like