Tutorials

C Data Types


Data Types in C


Data type in C is an indicator of the kind of value the variable is capable to hold.

For example, data type int will hold integer value, char will hold character value, type array will hold values of homogeneous type and so on.

 

Data types in C can be categorized as below:

  1. Basic data type → int, char, float, double
  2. Derived data type → array, pointer, structure, union
  3. Enumeration data type → enum
  4. Void data type → void

The image given below clearly depicts the above explanation about data types in C

:

              c data types by tutorialsinhand.com

 

Each data types has certain minimum requirement of memory space to hold the respective type of value in it.

 

Significance of data types

  • Data types is used to inform the compiler what kinds of values is stored.
  • How much space the values will occupy in memory.
  • The data types storage space may vary depending on the machine (32 bits or 64 bits) of the primary data types


Please Share this page
Views : 100
Like every other website we use cookies. By using our site you acknowledge that you have read and understand our Cookie Policy, Privacy Policy, and our Terms of Service. Learn more Got it!