adsense


Monday, 23 November 2015

C++ LANGUAGE DECLARING ARRAYS PAGE 80

COMPUTER LANGUAGES HTML,C,C++.JAVA,.NET AND MULTIMEDIA basics and programs click home button



C++ LANGUAGE DECLARING ARRAYS






 
Declaring Arrays 


To declare an array in C++, the programmer specifies 
the type of the elements and the number of elements 
required by an array as follows:
 
type arrayName [ arraySize ]; 

This is called a single-dimension array. The arraySize 
must be an integer constant greater than zero and type 
can be any valid C++ data type. For example, to declare 
a 10-element array called balance of type double, 
use this statement: 


double balance[10]; 


No comments: