SlideShare a Scribd company logo
1 of 12
By Ansh Kashyap
DATA TYPES IN C
BCA 1 semester
Section B
In the C Programming language, data types refer to a broad system used for
declaring variables or functions of different types. The type of a variable determines
how much space it occupies in storage and how the bit pattern stored is interpreted.
DATA TYPES
TYPES OF DATA TYPES
DATA TYPES
Primary Derived
Int Char
Float Type Void
User Define
Enumerated Typedef
Structure
Array Pointer
Integers are whole numbers with a range of values, range of values are machine
dependant. Generally an integer occupies 2 bytes memory space and its value range
limited to -32768 to +32767.
INT DATA TYPES
Data Type ControlString Size Range
Int %d 2 bytes -32768 to 32767
Long int %ld 4 bytes -2 to +2
Unsigned int %u 2 bytes 0 to 65535
31 31
Character type variable can hold a single character. As there are signed and
unsigned int (either short or long), in the same way there are signed and unsigned
chars; both occupy 1 byte each, but having different ranges Unsigned characters
have values between 0 and 255; signed character have from -128 to 127.
CHAR DATA TYPE
The float data type is used to store fractional numbers (real numbers) with 6 digits of
precision. Floating point number is insufficient, we can use the double to define the
number. The double is same as float but with longer precision and takes double
space (8 bytes) than float. To extend the precision further we can use long double
which occupies 10 bytes of memory space.
FLOAT DATA TYPE
Data Type Size Value Range Precision
float 4 byte 1.2E-38 to
3.4E+38
6 Decimal places
double 8 byte 2.3E-308 to
1.7E+308
15 Decimal places
Long double 10 byte 3.4E-4932 to
1.1E+4932
19 Decimal places
The void data types has no values therefore we cannot declare it as variable as we
did in case of integer and float. The void data type is usually used with function to
specify its type. Like in our first C program we declared “main()” as void type because
it does not return any value.
TYPE VOID DATA TYPE
Array: An array in C language is a collection of similar data-type, means an array
can hold value of a particular data type for which it has been declared. Arrays can be
created from any of the C data-type int.
DERIVED DATA TYPE
Pointer: C Pointer is a special variable that can be used to store address of another
variable.
Enumerated data type is a user defined data type having finite set of enumeration
constants. The keyword ‘enum’ is used to create enumerated data type. Enumeration
data type consists of named integer constants as a list. It start with 0 (zero) by default
and value is incremented by 1 for the sequential identifiers in the list.
ENUMERATED DATA
TYPE (ENUM)
Syntax:
Enum [data_type] {const1,const2…….constn};
Enum examples in C:
enum month { Jan, Feb, Mar }; or /* Jan, Feb and Mar variables will be assigned to 0, 1 and 2
respectively by default */
enum month { Jan = 1, Feb, Mar }; /* Feb and Mar variables will be assigned to 2 and 3
respectively by default */
It is used to create new data type. But it is commonly used to change existing data
type with another name.
TYPEDEF DATA TYPE
Syntax:
typedef [data_type] new_data_type;
Example:
Typedef int integer;
Integer roll_no;
C Structure is a collection of different data types which are grouped together and
each element in a C structure is called member.
TYPEDEF DATA TYPE
Example:
struct student {
Int roll_no;
char name[20];
char city[20];
}
THANK YOU

More Related Content

What's hot

C presentation book
C presentation bookC presentation book
C presentation bookkrunal1210
 
Data Types and Variables In C Programming
Data Types and Variables In C ProgrammingData Types and Variables In C Programming
Data Types and Variables In C ProgrammingKamal Acharya
 
Introduction to C Programming
Introduction to C ProgrammingIntroduction to C Programming
Introduction to C ProgrammingMOHAMAD NOH AHMAD
 
C programming tutorial
C programming tutorialC programming tutorial
C programming tutorialMohit Saini
 
Constant, variables, data types
Constant, variables, data typesConstant, variables, data types
Constant, variables, data typesPratik Devmurari
 
Data Type in C Programming
Data Type in C ProgrammingData Type in C Programming
Data Type in C ProgrammingQazi Shahzad Ali
 
constants, variables and datatypes in C
constants, variables and datatypes in Cconstants, variables and datatypes in C
constants, variables and datatypes in CSahithi Naraparaju
 
3 data-types-in-c
3 data-types-in-c3 data-types-in-c
3 data-types-in-cteach4uin
 
Programming in C Presentation upto FILE
Programming in C Presentation upto FILEProgramming in C Presentation upto FILE
Programming in C Presentation upto FILEDipta Saha
 
Unit 4 Foc
Unit 4 FocUnit 4 Foc
Unit 4 FocJAYA
 
C Programming: Control Structure
C Programming: Control StructureC Programming: Control Structure
C Programming: Control StructureSokngim Sa
 
Concept of c data types
Concept of c data typesConcept of c data types
Concept of c data typesManisha Keim
 
Introduction of c programming
Introduction of c programmingIntroduction of c programming
Introduction of c programmingTarun Sharma
 
Variables in python
Variables in pythonVariables in python
Variables in pythonJaya Kumari
 

What's hot (20)

C presentation book
C presentation bookC presentation book
C presentation book
 
Character set of c
Character set of cCharacter set of c
Character set of c
 
Data Types and Variables In C Programming
Data Types and Variables In C ProgrammingData Types and Variables In C Programming
Data Types and Variables In C Programming
 
Introduction to C Programming
Introduction to C ProgrammingIntroduction to C Programming
Introduction to C Programming
 
Data types in C
Data types in CData types in C
Data types in C
 
C programming tutorial
C programming tutorialC programming tutorial
C programming tutorial
 
Introduction to c++
Introduction to c++Introduction to c++
Introduction to c++
 
Constant, variables, data types
Constant, variables, data typesConstant, variables, data types
Constant, variables, data types
 
Data Type in C Programming
Data Type in C ProgrammingData Type in C Programming
Data Type in C Programming
 
Introduction to c programming
Introduction to c programmingIntroduction to c programming
Introduction to c programming
 
constants, variables and datatypes in C
constants, variables and datatypes in Cconstants, variables and datatypes in C
constants, variables and datatypes in C
 
3 data-types-in-c
3 data-types-in-c3 data-types-in-c
3 data-types-in-c
 
Programming in C Presentation upto FILE
Programming in C Presentation upto FILEProgramming in C Presentation upto FILE
Programming in C Presentation upto FILE
 
C keywords and identifiers
C keywords and identifiersC keywords and identifiers
C keywords and identifiers
 
Unit 4 Foc
Unit 4 FocUnit 4 Foc
Unit 4 Foc
 
C Programming: Control Structure
C Programming: Control StructureC Programming: Control Structure
C Programming: Control Structure
 
C if else
C if elseC if else
C if else
 
Concept of c data types
Concept of c data typesConcept of c data types
Concept of c data types
 
Introduction of c programming
Introduction of c programmingIntroduction of c programming
Introduction of c programming
 
Variables in python
Variables in pythonVariables in python
Variables in python
 

Similar to Data types in C

cassignmentii-170424105623.pdf
cassignmentii-170424105623.pdfcassignmentii-170424105623.pdf
cassignmentii-170424105623.pdfYRABHI
 
Data Types | CS8251- Programming in c | Learn Hub
Data Types | CS8251- Programming in c | Learn HubData Types | CS8251- Programming in c | Learn Hub
Data Types | CS8251- Programming in c | Learn HubLearn Hub
 
Constants Variables Datatypes by Mrs. Sowmya Jyothi
Constants Variables Datatypes by Mrs. Sowmya JyothiConstants Variables Datatypes by Mrs. Sowmya Jyothi
Constants Variables Datatypes by Mrs. Sowmya JyothiSowmyaJyothi3
 
Variables in C++, data types in c++
Variables in C++, data types in c++Variables in C++, data types in c++
Variables in C++, data types in c++Neeru Mittal
 
variablesfinal-170820055428 data type results
variablesfinal-170820055428 data type resultsvariablesfinal-170820055428 data type results
variablesfinal-170820055428 data type resultsatifmugheesv
 
Programming Fundamentals lecture 6
Programming Fundamentals lecture 6Programming Fundamentals lecture 6
Programming Fundamentals lecture 6REHAN IJAZ
 
C PROGRAMMING LANGUAGE
C  PROGRAMMING  LANGUAGEC  PROGRAMMING  LANGUAGE
C PROGRAMMING LANGUAGEPRASANYA K
 
UNIT-II VISUAL BASIC.NET | BCA
UNIT-II VISUAL BASIC.NET | BCAUNIT-II VISUAL BASIC.NET | BCA
UNIT-II VISUAL BASIC.NET | BCARaj vardhan
 
Enumerated data types in C
Enumerated data types in CEnumerated data types in C
Enumerated data types in CArpana shree
 
Concept Of C++ Data Types
Concept Of C++ Data TypesConcept Of C++ Data Types
Concept Of C++ Data Typesk v
 
Module 1:Introduction
Module 1:IntroductionModule 1:Introduction
Module 1:Introductionnikshaikh786
 
5-Lec - Datatypes.ppt
5-Lec - Datatypes.ppt5-Lec - Datatypes.ppt
5-Lec - Datatypes.pptAqeelAbbas94
 
C data types, arrays and structs
C data types, arrays and structsC data types, arrays and structs
C data types, arrays and structsSaad Sheikh
 
Fundamental of C Programming (Data Types)
Fundamental of C Programming (Data Types)Fundamental of C Programming (Data Types)
Fundamental of C Programming (Data Types)jimmy majumder
 

Similar to Data types in C (20)

C++ data types
C++ data typesC++ data types
C++ data types
 
Data types
Data typesData types
Data types
 
cassignmentii-170424105623.pdf
cassignmentii-170424105623.pdfcassignmentii-170424105623.pdf
cassignmentii-170424105623.pdf
 
Data Types | CS8251- Programming in c | Learn Hub
Data Types | CS8251- Programming in c | Learn HubData Types | CS8251- Programming in c | Learn Hub
Data Types | CS8251- Programming in c | Learn Hub
 
Constants Variables Datatypes by Mrs. Sowmya Jyothi
Constants Variables Datatypes by Mrs. Sowmya JyothiConstants Variables Datatypes by Mrs. Sowmya Jyothi
Constants Variables Datatypes by Mrs. Sowmya Jyothi
 
Variables in C++, data types in c++
Variables in C++, data types in c++Variables in C++, data types in c++
Variables in C++, data types in c++
 
variablesfinal-170820055428 data type results
variablesfinal-170820055428 data type resultsvariablesfinal-170820055428 data type results
variablesfinal-170820055428 data type results
 
Programming Fundamentals lecture 6
Programming Fundamentals lecture 6Programming Fundamentals lecture 6
Programming Fundamentals lecture 6
 
Data Handling
Data HandlingData Handling
Data Handling
 
Datatypes
DatatypesDatatypes
Datatypes
 
C PROGRAMMING LANGUAGE
C  PROGRAMMING  LANGUAGEC  PROGRAMMING  LANGUAGE
C PROGRAMMING LANGUAGE
 
Data types
Data typesData types
Data types
 
UNIT-II VISUAL BASIC.NET | BCA
UNIT-II VISUAL BASIC.NET | BCAUNIT-II VISUAL BASIC.NET | BCA
UNIT-II VISUAL BASIC.NET | BCA
 
Enumerated data types in C
Enumerated data types in CEnumerated data types in C
Enumerated data types in C
 
Concept Of C++ Data Types
Concept Of C++ Data TypesConcept Of C++ Data Types
Concept Of C++ Data Types
 
Module 1:Introduction
Module 1:IntroductionModule 1:Introduction
Module 1:Introduction
 
5-Lec - Datatypes.ppt
5-Lec - Datatypes.ppt5-Lec - Datatypes.ppt
5-Lec - Datatypes.ppt
 
C data types, arrays and structs
C data types, arrays and structsC data types, arrays and structs
C data types, arrays and structs
 
Data types
Data typesData types
Data types
 
Fundamental of C Programming (Data Types)
Fundamental of C Programming (Data Types)Fundamental of C Programming (Data Types)
Fundamental of C Programming (Data Types)
 

Recently uploaded

Unlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language ModelsUnlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language Modelsaagamshah0812
 
Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...OnePlan Solutions
 
Professional Resume Template for Software Developers
Professional Resume Template for Software DevelopersProfessional Resume Template for Software Developers
Professional Resume Template for Software DevelopersVinodh Ram
 
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...stazi3110
 
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...harshavardhanraghave
 
Introduction to Decentralized Applications (dApps)
Introduction to Decentralized Applications (dApps)Introduction to Decentralized Applications (dApps)
Introduction to Decentralized Applications (dApps)Intelisync
 
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfLearn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfkalichargn70th171
 
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASE
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASEBATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASE
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASEOrtus Solutions, Corp
 
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdfThe Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdfkalichargn70th171
 
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...kellynguyen01
 
EY_Graph Database Powered Sustainability
EY_Graph Database Powered SustainabilityEY_Graph Database Powered Sustainability
EY_Graph Database Powered SustainabilityNeo4j
 
Unit 1.1 Excite Part 1, class 9, cbse...
Unit 1.1 Excite Part 1, class 9, cbse...Unit 1.1 Excite Part 1, class 9, cbse...
Unit 1.1 Excite Part 1, class 9, cbse...aditisharan08
 
Building Real-Time Data Pipelines: Stream & Batch Processing workshop Slide
Building Real-Time Data Pipelines: Stream & Batch Processing workshop SlideBuilding Real-Time Data Pipelines: Stream & Batch Processing workshop Slide
Building Real-Time Data Pipelines: Stream & Batch Processing workshop SlideChristina Lin
 
5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdfWave PLM
 
TECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providerTECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providermohitmore19
 
Der Spagat zwischen BIAS und FAIRNESS (2024)
Der Spagat zwischen BIAS und FAIRNESS (2024)Der Spagat zwischen BIAS und FAIRNESS (2024)
Der Spagat zwischen BIAS und FAIRNESS (2024)OPEN KNOWLEDGE GmbH
 
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...soniya singh
 
why an Opensea Clone Script might be your perfect match.pdf
why an Opensea Clone Script might be your perfect match.pdfwhy an Opensea Clone Script might be your perfect match.pdf
why an Opensea Clone Script might be your perfect match.pdfjoe51371421
 
DNT_Corporate presentation know about us
DNT_Corporate presentation know about usDNT_Corporate presentation know about us
DNT_Corporate presentation know about usDynamic Netsoft
 
Cloud Management Software Platforms: OpenStack
Cloud Management Software Platforms: OpenStackCloud Management Software Platforms: OpenStack
Cloud Management Software Platforms: OpenStackVICTOR MAESTRE RAMIREZ
 

Recently uploaded (20)

Unlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language ModelsUnlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language Models
 
Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...Advancing Engineering with AI through the Next Generation of Strategic Projec...
Advancing Engineering with AI through the Next Generation of Strategic Projec...
 
Professional Resume Template for Software Developers
Professional Resume Template for Software DevelopersProfessional Resume Template for Software Developers
Professional Resume Template for Software Developers
 
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
 
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
 
Introduction to Decentralized Applications (dApps)
Introduction to Decentralized Applications (dApps)Introduction to Decentralized Applications (dApps)
Introduction to Decentralized Applications (dApps)
 
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdfLearn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
Learn the Fundamentals of XCUITest Framework_ A Beginner's Guide.pdf
 
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASE
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASEBATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASE
BATTLEFIELD ORM: TIPS, TACTICS AND STRATEGIES FOR CONQUERING YOUR DATABASE
 
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdfThe Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
The Essentials of Digital Experience Monitoring_ A Comprehensive Guide.pdf
 
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
 
EY_Graph Database Powered Sustainability
EY_Graph Database Powered SustainabilityEY_Graph Database Powered Sustainability
EY_Graph Database Powered Sustainability
 
Unit 1.1 Excite Part 1, class 9, cbse...
Unit 1.1 Excite Part 1, class 9, cbse...Unit 1.1 Excite Part 1, class 9, cbse...
Unit 1.1 Excite Part 1, class 9, cbse...
 
Building Real-Time Data Pipelines: Stream & Batch Processing workshop Slide
Building Real-Time Data Pipelines: Stream & Batch Processing workshop SlideBuilding Real-Time Data Pipelines: Stream & Batch Processing workshop Slide
Building Real-Time Data Pipelines: Stream & Batch Processing workshop Slide
 
5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf
 
TECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service providerTECUNIQUE: Success Stories: IT Service provider
TECUNIQUE: Success Stories: IT Service provider
 
Der Spagat zwischen BIAS und FAIRNESS (2024)
Der Spagat zwischen BIAS und FAIRNESS (2024)Der Spagat zwischen BIAS und FAIRNESS (2024)
Der Spagat zwischen BIAS und FAIRNESS (2024)
 
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
 
why an Opensea Clone Script might be your perfect match.pdf
why an Opensea Clone Script might be your perfect match.pdfwhy an Opensea Clone Script might be your perfect match.pdf
why an Opensea Clone Script might be your perfect match.pdf
 
DNT_Corporate presentation know about us
DNT_Corporate presentation know about usDNT_Corporate presentation know about us
DNT_Corporate presentation know about us
 
Cloud Management Software Platforms: OpenStack
Cloud Management Software Platforms: OpenStackCloud Management Software Platforms: OpenStack
Cloud Management Software Platforms: OpenStack
 

Data types in C

  • 1. By Ansh Kashyap DATA TYPES IN C BCA 1 semester Section B
  • 2. In the C Programming language, data types refer to a broad system used for declaring variables or functions of different types. The type of a variable determines how much space it occupies in storage and how the bit pattern stored is interpreted. DATA TYPES
  • 3. TYPES OF DATA TYPES DATA TYPES Primary Derived Int Char Float Type Void User Define Enumerated Typedef Structure Array Pointer
  • 4. Integers are whole numbers with a range of values, range of values are machine dependant. Generally an integer occupies 2 bytes memory space and its value range limited to -32768 to +32767. INT DATA TYPES Data Type ControlString Size Range Int %d 2 bytes -32768 to 32767 Long int %ld 4 bytes -2 to +2 Unsigned int %u 2 bytes 0 to 65535 31 31
  • 5. Character type variable can hold a single character. As there are signed and unsigned int (either short or long), in the same way there are signed and unsigned chars; both occupy 1 byte each, but having different ranges Unsigned characters have values between 0 and 255; signed character have from -128 to 127. CHAR DATA TYPE
  • 6. The float data type is used to store fractional numbers (real numbers) with 6 digits of precision. Floating point number is insufficient, we can use the double to define the number. The double is same as float but with longer precision and takes double space (8 bytes) than float. To extend the precision further we can use long double which occupies 10 bytes of memory space. FLOAT DATA TYPE Data Type Size Value Range Precision float 4 byte 1.2E-38 to 3.4E+38 6 Decimal places double 8 byte 2.3E-308 to 1.7E+308 15 Decimal places Long double 10 byte 3.4E-4932 to 1.1E+4932 19 Decimal places
  • 7. The void data types has no values therefore we cannot declare it as variable as we did in case of integer and float. The void data type is usually used with function to specify its type. Like in our first C program we declared “main()” as void type because it does not return any value. TYPE VOID DATA TYPE
  • 8. Array: An array in C language is a collection of similar data-type, means an array can hold value of a particular data type for which it has been declared. Arrays can be created from any of the C data-type int. DERIVED DATA TYPE Pointer: C Pointer is a special variable that can be used to store address of another variable.
  • 9. Enumerated data type is a user defined data type having finite set of enumeration constants. The keyword ‘enum’ is used to create enumerated data type. Enumeration data type consists of named integer constants as a list. It start with 0 (zero) by default and value is incremented by 1 for the sequential identifiers in the list. ENUMERATED DATA TYPE (ENUM) Syntax: Enum [data_type] {const1,const2…….constn}; Enum examples in C: enum month { Jan, Feb, Mar }; or /* Jan, Feb and Mar variables will be assigned to 0, 1 and 2 respectively by default */ enum month { Jan = 1, Feb, Mar }; /* Feb and Mar variables will be assigned to 2 and 3 respectively by default */
  • 10. It is used to create new data type. But it is commonly used to change existing data type with another name. TYPEDEF DATA TYPE Syntax: typedef [data_type] new_data_type; Example: Typedef int integer; Integer roll_no;
  • 11. C Structure is a collection of different data types which are grouped together and each element in a C structure is called member. TYPEDEF DATA TYPE Example: struct student { Int roll_no; char name[20]; char city[20]; }