Download presentation
Published bySherman McBride Modified over 8 years ago
1
Data Types Always data types will decide which type of information we are storing into variables In C programming language we are having 3 types of basic data types 1. char 2. int 3. float
2
. When the basic data types are not supporting user requirements then go for primitive data types primitive data types are constructed by extending the size and range of basic data types
3
. Type Size Range Format specifier Example char 1 byte -128 to +127 %c
‘a’ , ‘A’ unsigned char 0 to 255 int 2 byte to %d -25, 5, 0, -5 unsigned int 2 bytes 0 to 65535 %u 254, 36777 long int 4 bytes to %ld 45l, -5l, 5000l unsigned long 0 to %lu 1000l, 20000l float ±3.4*10±38 %f -3.5f ,125.13f double 8 bytes ±1.7*10±308 %lf , 270.6 long double 10 bytes ±3.4*10±4932 %Lf L, -1.2L
Similar presentations
© 2024 SlidePlayer.com. Inc.
All rights reserved.