DO NOT MISS

Ads

Friday 26 August 2016

Arrays in C-Language



In a Variable we can store only 1 value.

But if we want to store more than 1 value in the same Variable we should Arrays.

Collection of values with similar Datatype is known as Arrays. 

(or)

An array is a graph of related data items that store common name. For instance can define an array name"Marks" a set of marks of subscript in brackets after the array name. For example marks[10]. While the compute set of values is refer to as an array the individual values are called elements. Array can be any variable type. The ability to use a single name to represent a collection of items.



Syntax :-

Datatype arrayname [size];

here [] are subscrips.



Ex :-

int a[5];

Every Array values are stored in indexes. 
Every Array index starts with '0' and ends with 'size-1'.



TYPES OF ARRAYS

There are three types of Arrays.



      

______________________________________________________________________________
________________________________________________


Greataims

 
Copyright © 2016 Computersadda. Designed by @ Computersadda Team - Published By Greataims