SlideShare a Scribd company logo
1 of 36
 Consists of a set of predefined rules.
 These rules form the syntax of that language.
 Hence learning a programming language is
nothing but learning of that language.
 Computer can understand only instructions written
in binary code ( 0 and 1), They do not directly read
or understand a any programming language. And
so a programming language is converted into
binary code by using a special program called
compiler.
 A program which translates instructions written in
a programming language into binary code is called
a compiler.
 When we write a program in C Language, what we
write is called Source Code.
 The compiler’s output is called executable code.
 C is a programming language developed at
AT&T Bell laboratories around 1972.
 It was designed and written by Dennis M.
Ritchie.
 C was standardized in 1989 by American
National Standard Institute (ANSI). So it came
to be known as ANSI C.
 C is a structured language. It breaks up a
program into small parts known as functions.
 Flow chart
use to define flow of any program.
symbolic representation of program.
use different symbols.
 Rectangle
 Parallelogram
 Diamond
 Lines
 oval
 Use to define process in program
 Use to define input and output in program
 Use to specify condition in program
 To show flow of the program
 Use to declare start and end of flow chart and
connect flow chart with other flow chart
pages also.
start
end
Input
outputoutput
conditionProcess if
true
Process if
false
start
end
Insert value of i
Print value of I
is less than
five
Print value of
I is greater
than five
If(i<5)
Declare variable I
as integer
Documentation
Symbolic Constant Definition
File Include Section
Global Variable Declaration
Main()
{
Declaration
Executable Statements
}
Function 1 Function 2
Function n….
starting
Section
Compulsory
section for all
C Programs
User Defined
Functions
 Compile is one type of program to convert
source code into machine level code,
 Compiler compile the code of block and
return the error and warning list.
 #include <stdio.h>
 #include <conio.h>
 void main()
{
printf(“My first program”);
getch();
}
 #include <stdio.h>
 #include <conio.h>
# : is pre possessive directive.
use to include header files before
start the program.
 Header file is collection of pre define
functions.
 Extension of header file is must “.h”.
 Header files are located in “INCLUDE” folder
of “TC”.
 void main()
{
main()
c compile founds main() to start execution of
program.
must declare main function in every program.
 {
 braces use to define starting of coding block.
 printf(“My First program”);
 printf() : use to print any formatted
string in output window of
Turbo c.
header file : stdio.h
( standard input output )
 getch();
 }
 getch() use to get 1 character from
keyboard.
} define end of coding block.
 Compile the source code with.
Alt + F9
Run the program with.
Crtl + F9
 C language is totally case sensitive language.
 All the statements of C language must
terminate with semi colon ( ; )
 My First program
file type extension
 C- Source file .C
 application file .EXE
 object file .OBJ
 Comment lines ignore by c compiler
// use for single line comment
/* */ use for multiline comment
 Integer
 Float
 Double
 Character
 Signed integer
range -32,768 to 32,767
occupy first bit as a sigh bit.
( + / - )
memory space ( 2 bytes )
 Unsigned integer
range 0 to 65,535
not occupy any bit as sign bit.
memory space ( 2 bytes )
Note : to declare unsigned integer variable
must use unsigned key word before integer.
 Use to store values with fiction point.
memory space ( 4 bytes) 32 bits
Double 64 bits(8 bytes)
Long double 80 bits(10 bytes)
 Default unsigned character
 8 bits ( 1 byte )
 Range : 0 to 255
 Signed character
 8 bits ( 1 byte )
 Range : -128 to 127
 int a = 10;
 printf(“Value of variable a is : %d”,a);
 o/p : Value of variable a is : 10
 %d use for integer values
 %f use for float values
 %c use for character
 %s use for String
 %l use for double values
 %lf use for long double values
 Use
 scanf() function
 Syntax :
 scanf(“format character ”, &variable name);
 int a;
 printf(“Enter value of a ”);
 scanf(“%d”,&a);
 printf(“Value of variable a is : %d”,a);
 o/p value of variable a is : 10
Note : assume that we entered 10 from
keyboard.

More Related Content

What's hot

Programming Fundamentals Functions in C and types
Programming Fundamentals  Functions in C  and typesProgramming Fundamentals  Functions in C  and types
Programming Fundamentals Functions in C and typesimtiazalijoono
 
Let us c chapter 4 solution
Let us c chapter 4 solutionLet us c chapter 4 solution
Let us c chapter 4 solutionrohit kumar
 
Storage class in c
Storage class in cStorage class in c
Storage class in ckash95
 
Computer Fundamentals Chapter 11 pcp
Computer Fundamentals Chapter 11 pcpComputer Fundamentals Chapter 11 pcp
Computer Fundamentals Chapter 11 pcpSaumya Sahu
 
object oriented Programming ppt
object oriented Programming pptobject oriented Programming ppt
object oriented Programming pptNitesh Dubey
 
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
 
What is keyword in c programming
What is keyword in c programmingWhat is keyword in c programming
What is keyword in c programmingRumman Ansari
 
Programming For Problem Solving Lecture Notes
Programming For Problem Solving Lecture NotesProgramming For Problem Solving Lecture Notes
Programming For Problem Solving Lecture NotesSreedhar Chowdam
 
Basic Structure of C Language and Related Term
Basic Structure of C Language  and Related TermBasic Structure of C Language  and Related Term
Basic Structure of C Language and Related TermMuhammadWaseem305
 
Chapter 1 : Balagurusamy_ Programming ANsI in C
Chapter 1  :  Balagurusamy_ Programming ANsI in C Chapter 1  :  Balagurusamy_ Programming ANsI in C
Chapter 1 : Balagurusamy_ Programming ANsI in C BUBT
 
Constants in C Programming
Constants in C ProgrammingConstants in C Programming
Constants in C Programmingprogramming9
 
c++ programming Unit 2 basic structure of a c++ program
c++ programming Unit 2 basic structure of a c++ programc++ programming Unit 2 basic structure of a c++ program
c++ programming Unit 2 basic structure of a c++ programAAKASH KUMAR
 
Variables in C Programming
Variables in C ProgrammingVariables in C Programming
Variables in C Programmingprogramming9
 

What's hot (20)

String functions in C
String functions in CString functions in C
String functions in C
 
Storage classes in C
Storage classes in CStorage classes in C
Storage classes in C
 
Programming Fundamentals Functions in C and types
Programming Fundamentals  Functions in C  and typesProgramming Fundamentals  Functions in C  and types
Programming Fundamentals Functions in C and types
 
Let us c chapter 4 solution
Let us c chapter 4 solutionLet us c chapter 4 solution
Let us c chapter 4 solution
 
C string
C stringC string
C string
 
C functions
C functionsC functions
C functions
 
Storage class in c
Storage class in cStorage class in c
Storage class in c
 
Functions in C
Functions in CFunctions in C
Functions in C
 
Computer Fundamentals Chapter 11 pcp
Computer Fundamentals Chapter 11 pcpComputer Fundamentals Chapter 11 pcp
Computer Fundamentals Chapter 11 pcp
 
C tokens
C tokensC tokens
C tokens
 
object oriented Programming ppt
object oriented Programming pptobject oriented Programming ppt
object oriented Programming ppt
 
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
 
What is keyword in c programming
What is keyword in c programmingWhat is keyword in c programming
What is keyword in c programming
 
Storage class in C Language
Storage class in C LanguageStorage class in C Language
Storage class in C Language
 
Programming For Problem Solving Lecture Notes
Programming For Problem Solving Lecture NotesProgramming For Problem Solving Lecture Notes
Programming For Problem Solving Lecture Notes
 
Basic Structure of C Language and Related Term
Basic Structure of C Language  and Related TermBasic Structure of C Language  and Related Term
Basic Structure of C Language and Related Term
 
Chapter 1 : Balagurusamy_ Programming ANsI in C
Chapter 1  :  Balagurusamy_ Programming ANsI in C Chapter 1  :  Balagurusamy_ Programming ANsI in C
Chapter 1 : Balagurusamy_ Programming ANsI in C
 
Constants in C Programming
Constants in C ProgrammingConstants in C Programming
Constants in C Programming
 
c++ programming Unit 2 basic structure of a c++ program
c++ programming Unit 2 basic structure of a c++ programc++ programming Unit 2 basic structure of a c++ program
c++ programming Unit 2 basic structure of a c++ program
 
Variables in C Programming
Variables in C ProgrammingVariables in C Programming
Variables in C Programming
 

Similar to C Theory

Similar to C Theory (20)

Cp week _2.
Cp week _2.Cp week _2.
Cp week _2.
 
Unit 2 introduction to c programming
Unit 2   introduction to c programmingUnit 2   introduction to c programming
Unit 2 introduction to c programming
 
C Programming UNIT 1.pptx
C Programming  UNIT 1.pptxC Programming  UNIT 1.pptx
C Programming UNIT 1.pptx
 
(Lect. 2 & 3) Introduction to C.ppt
(Lect. 2 & 3) Introduction to C.ppt(Lect. 2 & 3) Introduction to C.ppt
(Lect. 2 & 3) Introduction to C.ppt
 
Learn c language Important topics ( Easy & Logical, & smart way of learning)
Learn c language Important topics ( Easy & Logical, & smart way of learning)Learn c language Important topics ( Easy & Logical, & smart way of learning)
Learn c language Important topics ( Easy & Logical, & smart way of learning)
 
Lect '1'
Lect '1'Lect '1'
Lect '1'
 
C++ programming language basic to advance level
C++ programming language basic to advance levelC++ programming language basic to advance level
C++ programming language basic to advance level
 
c_pro_introduction.pptx
c_pro_introduction.pptxc_pro_introduction.pptx
c_pro_introduction.pptx
 
C++ AND CATEGORIES OF SOFTWARE
C++ AND CATEGORIES OF SOFTWAREC++ AND CATEGORIES OF SOFTWARE
C++ AND CATEGORIES OF SOFTWARE
 
C notes
C notesC notes
C notes
 
C Lang notes.ppt
C Lang notes.pptC Lang notes.ppt
C Lang notes.ppt
 
C tutorials
C tutorialsC tutorials
C tutorials
 
Unit-1 (introduction to c language).pptx
Unit-1 (introduction to c language).pptxUnit-1 (introduction to c language).pptx
Unit-1 (introduction to c language).pptx
 
C programming
C programmingC programming
C programming
 
C programming
C programmingC programming
C programming
 
Bcsl 031 solve assignment
Bcsl 031 solve assignmentBcsl 031 solve assignment
Bcsl 031 solve assignment
 
Unit 1 c - all topics
Unit 1   c - all topicsUnit 1   c - all topics
Unit 1 c - all topics
 
over all view programming to computer
over all view programming to computer over all view programming to computer
over all view programming to computer
 
Introduction to c programming
Introduction to c programmingIntroduction to c programming
Introduction to c programming
 
Unit 2 ppt
Unit 2 pptUnit 2 ppt
Unit 2 ppt
 

More from Shyam Khant

More from Shyam Khant (8)

Unit2.data type, operators, control structures
Unit2.data type, operators, control structuresUnit2.data type, operators, control structures
Unit2.data type, operators, control structures
 
Introducing to core java
Introducing to core javaIntroducing to core java
Introducing to core java
 
C++
C++C++
C++
 
Php
PhpPhp
Php
 
C++ theory
C++ theoryC++ theory
C++ theory
 
Java script
Java scriptJava script
Java script
 
SQL
SQLSQL
SQL
 
Hashing 1
Hashing 1Hashing 1
Hashing 1
 

Recently uploaded

Grant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy ConsultingGrant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy ConsultingTechSoup
 
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdfssuser54595a
 
CARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxCARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxGaneshChakor2
 
Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104misteraugie
 
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityGeoBlogs
 
Interactive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationInteractive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationnomboosow
 
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...RKavithamani
 
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdfBASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdfSoniaTolstoy
 
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...EduSkills OECD
 
Mastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory InspectionMastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory InspectionSafetyChain Software
 
Beyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global ImpactBeyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global ImpactPECB
 
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Sapana Sha
 
Accessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactAccessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactdawncurless
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introductionMaksud Ahmed
 
URLs and Routing in the Odoo 17 Website App
URLs and Routing in the Odoo 17 Website AppURLs and Routing in the Odoo 17 Website App
URLs and Routing in the Odoo 17 Website AppCeline George
 
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Krashi Coaching
 
Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)eniolaolutunde
 
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptxContemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptxRoyAbrique
 
Student login on Anyboli platform.helpin
Student login on Anyboli platform.helpinStudent login on Anyboli platform.helpin
Student login on Anyboli platform.helpinRaunakKeshri1
 

Recently uploaded (20)

Grant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy ConsultingGrant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy Consulting
 
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
 
CARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxCARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptx
 
Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104
 
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activity
 
Interactive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationInteractive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communication
 
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...
 
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdfBASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
 
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
 
Mastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory InspectionMastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory Inspection
 
Beyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global ImpactBeyond the EU: DORA and NIS 2 Directive's Global Impact
Beyond the EU: DORA and NIS 2 Directive's Global Impact
 
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
 
Accessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impactAccessible design: Minimum effort, maximum impact
Accessible design: Minimum effort, maximum impact
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introduction
 
URLs and Routing in the Odoo 17 Website App
URLs and Routing in the Odoo 17 Website AppURLs and Routing in the Odoo 17 Website App
URLs and Routing in the Odoo 17 Website App
 
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
Mattingly "AI & Prompt Design: Structured Data, Assistants, & RAG"
 
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
 
Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)Software Engineering Methodologies (overview)
Software Engineering Methodologies (overview)
 
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptxContemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
Contemporary philippine arts from the regions_PPT_Module_12 [Autosaved] (1).pptx
 
Student login on Anyboli platform.helpin
Student login on Anyboli platform.helpinStudent login on Anyboli platform.helpin
Student login on Anyboli platform.helpin
 

C Theory

  • 1.
  • 2.  Consists of a set of predefined rules.  These rules form the syntax of that language.  Hence learning a programming language is nothing but learning of that language.
  • 3.  Computer can understand only instructions written in binary code ( 0 and 1), They do not directly read or understand a any programming language. And so a programming language is converted into binary code by using a special program called compiler.  A program which translates instructions written in a programming language into binary code is called a compiler.  When we write a program in C Language, what we write is called Source Code.  The compiler’s output is called executable code.
  • 4.  C is a programming language developed at AT&T Bell laboratories around 1972.  It was designed and written by Dennis M. Ritchie.  C was standardized in 1989 by American National Standard Institute (ANSI). So it came to be known as ANSI C.  C is a structured language. It breaks up a program into small parts known as functions.
  • 5.  Flow chart use to define flow of any program. symbolic representation of program. use different symbols.
  • 6.  Rectangle  Parallelogram  Diamond  Lines  oval
  • 7.  Use to define process in program
  • 8.  Use to define input and output in program
  • 9.  Use to specify condition in program
  • 10.  To show flow of the program
  • 11.  Use to declare start and end of flow chart and connect flow chart with other flow chart pages also.
  • 13. start end Insert value of i Print value of I is less than five Print value of I is greater than five If(i<5) Declare variable I as integer
  • 14. Documentation Symbolic Constant Definition File Include Section Global Variable Declaration Main() { Declaration Executable Statements } Function 1 Function 2 Function n…. starting Section Compulsory section for all C Programs User Defined Functions
  • 15.  Compile is one type of program to convert source code into machine level code,  Compiler compile the code of block and return the error and warning list.
  • 16.  #include <stdio.h>  #include <conio.h>  void main() { printf(“My first program”); getch(); }
  • 17.  #include <stdio.h>  #include <conio.h> # : is pre possessive directive. use to include header files before start the program.
  • 18.  Header file is collection of pre define functions.  Extension of header file is must “.h”.  Header files are located in “INCLUDE” folder of “TC”.
  • 19.  void main() { main() c compile founds main() to start execution of program. must declare main function in every program.
  • 20.  {  braces use to define starting of coding block.
  • 21.  printf(“My First program”);  printf() : use to print any formatted string in output window of Turbo c. header file : stdio.h ( standard input output )
  • 22.  getch();  }  getch() use to get 1 character from keyboard. } define end of coding block.
  • 23.  Compile the source code with. Alt + F9 Run the program with. Crtl + F9
  • 24.  C language is totally case sensitive language.  All the statements of C language must terminate with semi colon ( ; )
  • 25.  My First program
  • 26. file type extension  C- Source file .C  application file .EXE  object file .OBJ
  • 27.  Comment lines ignore by c compiler // use for single line comment /* */ use for multiline comment
  • 28.  Integer  Float  Double  Character
  • 29.  Signed integer range -32,768 to 32,767 occupy first bit as a sigh bit. ( + / - ) memory space ( 2 bytes )
  • 30.  Unsigned integer range 0 to 65,535 not occupy any bit as sign bit. memory space ( 2 bytes ) Note : to declare unsigned integer variable must use unsigned key word before integer.
  • 31.  Use to store values with fiction point. memory space ( 4 bytes) 32 bits Double 64 bits(8 bytes) Long double 80 bits(10 bytes)
  • 32.  Default unsigned character  8 bits ( 1 byte )  Range : 0 to 255  Signed character  8 bits ( 1 byte )  Range : -128 to 127
  • 33.  int a = 10;  printf(“Value of variable a is : %d”,a);  o/p : Value of variable a is : 10
  • 34.  %d use for integer values  %f use for float values  %c use for character  %s use for String  %l use for double values  %lf use for long double values
  • 35.  Use  scanf() function  Syntax :  scanf(“format character ”, &variable name);
  • 36.  int a;  printf(“Enter value of a ”);  scanf(“%d”,&a);  printf(“Value of variable a is : %d”,a);  o/p value of variable a is : 10 Note : assume that we entered 10 from keyboard.