Professional Documents
Culture Documents
Home Tutorials Software Testing Programing Data Management Certification Career Center Skill Test
Learn Oracle Learn Microsoft Learn J2EE Learn Networking Learn Concepts
http://www.exforsys.com/tutorials/c-language/c-arrays.html 8/4/2010
C Programming - Arrays Page 2 of 3
C Programming - Functions
(Part-I)
p>The C language provides a capability that enables the user to define a set of ordered data ite
C Programming - Handling of array.
character string
Suppose we had a set of grades that we wished to read into the computer and suppos
C Programming - Arrays
perform some operations on these grades, we will quickly realize that we cannot pe
C Programming - Decision operation until each and every grade has been entered since it would be quite a tedious
Making - Looping each and every student grade as a variable especially since there may be a very large num
C Programming - Decision
Making - Branching In C we can define variable called grades, which represents not a single value of grade bu
grades. Each element of the set can then be referenced by means of a number called
C Programming - Managing subscript.
Input and Output Operations
C Programming - An Overview
type variable-name[50];
C Programming - Constants
and Variables The type specifies the type of the elements that will be contained in the array, such as int f
the size indicates the maximum number of elements that can be stored inside the array for
float height[50];
Declares the height to be an array containing 50 real elements. Any subscripts 0 to 49 are
array elements index or subscript begins with number zero. So height [0] refers to the firs
array. (For this reason, it is easier to think of it as referring to element number zero,
referring to the first element).
http://www.exforsys.com/tutorials/c-language/c-arrays.html 8/4/2010
C Programming - Arrays Page 3 of 3
Partners -
http://www.exforsys.com/tutorials/c-language/c-arrays.html 8/4/2010