C - Non Primitive Data Types




C Non Primitive Data Types - Definition and Usage

  • The data types that are derived from primary data types are known as non-Primitive data types.
  • The non-primitive datatypes are used to store group of values.
  • The non-primitive data types are :
C Non Primitive Data Types

Arrays :

  • An array is a collection of data items , all of the same type , accessed using a common name.
  • C language places no limits on the number of dimensions in an array, though specific implementations.

C Syntax

type arrayName [ arraySize ];

String :

  • In C programming, Strings are represented by array of characters.
  • A string is terminated by null character /0.
  • Strings are always enclosed by double quotes (Example: “Wikitechy”) . Whereas, character is enclosed by single quotes in C (Example: ‘W’).

C Syntax

char name[size]= ”string”;
char ‘C’;

Structures :

  • Structure is the collection of variables of different types under a single name for better handling.

C Syntax

struct structure_name 
{
    data_type member1;
    data_type member2;
    .
    .
    data_type memeber;
};


View More Quick Examples


Related Searches to C Non Primitive Data Types

Adblocker detected! Please consider reading this notice.

We've detected that you are using AdBlock Plus or some other adblocking software which is preventing the page from fully loading.

We don't have any banner, Flash, animation, obnoxious sound, or popup ad. We do not implement these annoying types of ads!

We need money to operate the site, and almost all of it comes from our online advertising.

Please add wikitechy.com to your ad blocking whitelist or disable your adblocking software.

×