Arrays refer to a list of finite number of same data types. The data in the array can be accessed by an index number ranging from 0 to n(where n is the number of data element it can store). Ex- if arr[3] is an array of int(egers) then the different values in the array can be accessed as shown below. arr[0], arr[1],arr[2] when we declare an array such as the one sown above then by arr[3] we mean that we want three elements in the array and hence while accessing arr[2] is the last element.
In c++,why is an array called a derived data type?
All details about c++ language is in the website www.cplusplus.com.so pls refer there.
Reply:the array could be functionally called the data.
Reply:First you gotta know what a primitive data type is . Primitives are like integers, floats, doubles. But an array actually consists of a bunch of one type of these primitives, thus being a derived data type . I hope this helps...
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment