top button
Flag Notify
    Connect to us
      Site Registration

Site Registration

Is array predefined datatype or secondary data type?

+1 vote
493 views
Is array predefined datatype or secondary data type?
posted Jun 18, 2016 by Bhavanacheedella

Share this question
Facebook Share Button Twitter Share Button LinkedIn Share Button

2 Answers

+2 votes

Datatype is a spacial keyword used to allocate sufficient memory space for the data, or you can say data type is used for representing the data in main memory (RAM) of the computer.
Derived data types are those whose variables allow us to store multiple values of same type. But they never allows to store multiple values of different types. These are the data type whose variable can hold more than one value of similar type. In general derived data type can be achieve using array.So array is seconday data type.

answer Jun 28, 2016 by Shivam Kumar Pandey
+1 vote

Lets first understand the various classification of Data Types
1. Fundamental or Built-in data types (Primary Data Types).
2. Derived data types (Secondary Data Types).
3. User Defined data types.

The basic built-in or fundamental data types that are available in any programming language, in C we have int, float, double and char as builtin data types.
Derived data types are those data types which are derived from the fundamental data types using some declaration operators. In C we have Arrays, Functions and pointers, Structures and Classes as derived or secondary data types.

I hope this will clear your doubt.

answer Jun 18, 2016 by Tapesh Kulkarni
Similar Questions
+1 vote

I have seen the pre-defined identifier __func__ in many code bases. I want to know, when it is used and benefits of using it ?

0 votes

Which is the best practice for variable declaration within the function ? Or is it vary from one language to other one ?

...