Priya424726 please help me explain about datatypes in computer. please. u get more marks. add ur contact.
Answers
Answer:
- In computer science and computer programming, a data type or simply type is an attribute of data which tells the compiler or interpreter how the programmer intends to use the data. ... This data type defines the operations that can be done on the data, the meaning of the data, and the way values of that type can be stored.
Answer:
C data types are defined as the data storage format that a variable can store a data to perform a specific operation.
Data types are used to define a variable before to use in a program.
Size of variable, constant and array are determined by data types.
C – DATA TYPES:
There are four data types in C language. They
INTEGER DATA TYPE:
Integer data type allows a variable to store numeric values.
“int” keyword is used to refer integer data type.
The storage size of int data type is 2 or 4 or 8 byte.
It varies depend upon the processor in the CPU that we use. If we are using 16 bit processor, 2 byte (16 bit) of memory will be allocated for int data type.
Like wise, 4 byte (32 bit) of memory for 32 bit processor and 8 byte (64 bit) of memory for 64 bit processor is allocated for int datatype.
int (2 byte) can store values from -32,768 to +32,767
int (4 byte) can store values from -2,147,483,648 to +2,147,483,647.
If you want to use the integer value that crosses the above limit, you can go for “long int” and “long long int” for which the limits are very high.