Sunday, December 16, 2018

CLASSIFICATION OF DATA TYPES.

/*CLASSIFICATION OF DATA TYPE.*/
sk.
*PRIMARY DATA TYPE:-

  •   Integer data types:- These are used to store numeric data items. They can store whole number as well as numbers with fractions. The data type of this categories are integer, short integer, long integer. In addition to these type unsigned int, unsigned short int, and unsigned long int are also lies in this category. Integer occupy one word in the numbering. The length of the word may vary and it is typically 16 or 32 bits.
  •  FLOATING POINT TYPE:- These are used to store number with fraction.
  •  CHARACTER DATA TYPE:- These are used to store character data items. The value to be stored in them are enclosed in single quotation mark ('') char and unsigned char are two character data type.
* SECONDARY/DERIVED DATA TYPE:- These are also called structure data type. The main difference between fundamental and derived data type is that a variables of derived data types can handle more than one value data type but in variable of fundamental data type it can handle only one value data type. They are also called secondary data type. Example:- array, string, union etc.
  • USER DEFINED DATA TYPE:- These are the data types that are defined by the user. The contain users specified values "enum". keyword is used to declare data types of this type.
  • POINTER DATA TYPE:- A pointer is a data type that handles the data as per as its memory address.
  • VOID DATA TYPES:- It represent null or empty. This is used when a particular function does not return any value.

No comments:

Post a Comment

Wikipedia

Search results

Search The program