SlideShare a Scribd company logo
1
2
• C programming language was developed in
1972 by Dennis Ritchie at bell laboratories of
AT&T (American Telephone & Telegraph),
located in the U.S.A..
• It was initially designed for programming in
UNIX operating system.
• Now the software tool as well as the C
compiler is written in C. Major parts of popular
operating systems like Windows, UNIX, Linux
is still written in C.
3
• C is one of the most popular languages used today.
• C is a robust programming with an impressive set of built-in functions
and a variety of operators which you can use to write any complex
program.
• C programs are fast and efficient. This is because C uses a powerful
set of
data types and operators.
• C combines the power and capability of assembly language with the
user friendly features of a high-level language.
• C is the most widely used older programming language. It continues to
go strong while older programming languages such as BASIC and
COBOL have been virtually forgotten.
• C is very much portable, which means programs written on a machine
using C can be used on other machines as well without any
modification.
• A C program consists of a number of functions that are supported by C
library. In fact, you can create your own function, which can then be
added to the C library.
4
• C is a General Purpose Programming Language. This means C can be
used to write a variety of applications. It is often referred to as a “system
programming language.”
• C is a middle level language, which means it combines the features of
high
level language with the functionality of an assembly language.
• C is a structured programming language, which means as a programmer,
you are required to divide a problem into a several different modules or
functions.
• C is renowned for its simplicity and is easy to use because of its
structured approach. It has a vast collection of keywords, operators, built-
in functions and data types which make it efficient and powerful.
• C is portable, which means a C program runs in different environments. C
compilers are available for all operating systems and hardware platforms.
Additionally, you can easily write code on one system and port it to
another.
• C is popular not just because it can be used as a standalone
programming language, but also as it can be used as an interface to
other more visual languages.
5
• C is a very flexible language; it is convenient and portable, like a high level
language and flexible like a low level language. It can be interfaced with other
programming languages.
• C is super fast. The compilation and execution of programs is much faster on
C than with most other languages.
• C is modular, which means C programs can be divided into small modules,
which
are much easier to understand.
• C is easily available. The C software is easy to access and can be easily
installed on your computer. The installation of C hardly takes a few minutes.
• C is easy to debug. The C compiler detects syntax errors quickly and easily
and displays the errors along with the line numbers of the code and the error
message.
• C makes available a number of in-built memory management functions that
save memory and improve the efficiency of the program such as malloc(),
calloc() and alloc().
• Recursion is one of the common techniques used in C, where in a function
calls itself again and again.
• Finally, C has a rich set of library functions and supports graphic programming
too.
Learning C is easier. Instead of straight-away learning how to
write programs, we must first know what alphabets, numbers
and special symbols are used in C, then how using them
constants, variables and keywords are constructed, and
finally how are these combined to form an instruction. A
group of instructions would be combined later on to form a
program. a computer program is just a collection of the
instructions necessary to solve a specific problem. The basic
operations of a computer system form what is known as the
computer’s instruction set. And the approach or method that
is used to solve the problem is known as an algorithm.
6
7
• In machine level language computer only understand digital numbers
i.e. in the form of 0 and 1. So, instruction given to the computer is in
the form binary digit, which is difficult to implement instruction in
binary code
• The assembly language is on other hand modified version of
machine level language. Where instructions are given in English like
word as ADD, SUM, MOV etc. It is easy to write and understand but
not understand by the machine.
• High level languages are machine independent, means it is portable.
The language in this category is Pascal, Cobol, Fortran etc. High level
languages are understood by the machine. So it need to translate by
the translator into machine level. A translator is software which is
used to translate high level language as well as low level language in
to machine level language
8
Compiler and interpreter are used to convert the high
level language into machine level language. The program
written in high level language is known as source program
and the corresponding machine level language program
is called as object program. Both compiler and interpreter
perform the same task but there working is different.
Compiler read the program at-a-time and searches the
error and lists them. If the program is error free then it is
converted into object program. When program size is
large then compiler is preferred. Whereas interpreter read
only one line of the source code and convert it to object
code. If it check error, statement by statement and hence
of take more time.
9
C Comments
It indicates the purpose of the program. It is represented as
/
*
…
…
…
…
…
…
…
…
…
…
….
.
*
/ Comment line is used for increasing the
readability of the program. It is useful in explaining the program and
generally used for documentation. It is enclosed within the decimeters.
Comment line can be single or multiple line but should not be nested.
It can be anywhere in the program except inside string constant &
character constant.
Preprocessor Directive:
#include<stdio.h> tells the compiler to include information about the
standard input/output library. It is also used in symbolic constant such
as #define PI 3.14(value). The stdio.h (standard input output header
file) contains definition &declaration of system defined function such
as printf(
), scanf( ), pow( ) etc. Generally printf() function used to display and
scanf() function used to read value
10
Main function is the entry point of any C Program. It is the point from where the
execution of program is started
11
12
13
14
15
16
17
18
19
20
21
22
23
24
A switch statement tests the
value of a variable and
compares it with multiple
cases. Once the case match
is found, a block of
statements associated with
that particular case is
executed. The default case
is an optional one.
Whenever the value of test-
expression is not matched
with any of the cases inside
the switch, then the default
will be executed. Otherwise,
it is not necessary to write
default in the switch.
25
In computer programming, a loop is a sequence of instructions that is
repeated until a certain condition is reached.
There are mainly two types of loops:
Entry Controlled loops: In this type of loops the test condition is tested
before
entering the loop body. Loop and While Loops are entry controlled loops.
Exit Controlled Loops: In this type of loops the test condition is tested or
evaluated at the end of loop body. Therefore, the loop body will execute at
least once, irrespective of whether the test condition is true or false. do –
while loop is exit controlled loop.
26
27
28
Ad

More Related Content

What's hot (20)

Basics of c++ Programming Language
Basics of c++ Programming LanguageBasics of c++ Programming Language
Basics of c++ Programming Language
Ahmad Idrees
 
Programming Paradigm & Languages
Programming Paradigm & LanguagesProgramming Paradigm & Languages
Programming Paradigm & Languages
Gaditek
 
Basic programming concepts
Basic programming conceptsBasic programming concepts
Basic programming concepts
salmankhan570
 
Intro To Programming Concepts
Intro To Programming ConceptsIntro To Programming Concepts
Intro To Programming Concepts
Jussi Pohjolainen
 
Introduction of c language
Introduction of c languageIntroduction of c language
Introduction of c language
Akhilesh Maithani
 
C programming
C programmingC programming
C programming
Jigarthacker
 
Programming in c
Programming in cProgramming in c
Programming in c
indra Kishor
 
Programming Languages / Translators
Programming Languages / TranslatorsProgramming Languages / Translators
Programming Languages / Translators
Project Student
 
C LANGUAGE NOTES
C LANGUAGE NOTESC LANGUAGE NOTES
C LANGUAGE NOTES
Malikireddy Bramhananda Reddy
 
Programming languages
Programming languagesProgramming languages
Programming languages
Asmasum
 
Introduction to python
Introduction to pythonIntroduction to python
Introduction to python
Ayshwarya Baburam
 
introduction to programming languages
introduction to programming languagesintroduction to programming languages
introduction to programming languages
NaqashAhmad14
 
PPS UNIT 1- R18.docx
PPS UNIT 1- R18.docxPPS UNIT 1- R18.docx
PPS UNIT 1- R18.docx
Uzma1102
 
Introduction to Problem Solving Techniques- Python
Introduction to Problem Solving Techniques- PythonIntroduction to Problem Solving Techniques- Python
Introduction to Problem Solving Techniques- Python
PriyankaC44
 
Intro to assembly language
Intro to assembly languageIntro to assembly language
Intro to assembly language
United International University
 
Generations Of Programming Languages
Generations Of Programming LanguagesGenerations Of Programming Languages
Generations Of Programming Languages
py7rjs
 
Chapter 1 - An Introduction to Programming
Chapter 1 - An Introduction to ProgrammingChapter 1 - An Introduction to Programming
Chapter 1 - An Introduction to Programming
mshellman
 
Python Basics
Python BasicsPython Basics
Python Basics
primeteacher32
 
Introduction to programming
Introduction to programmingIntroduction to programming
Introduction to programming
Neeru Mittal
 
Programming Fundamentals lecture 1
Programming Fundamentals lecture 1Programming Fundamentals lecture 1
Programming Fundamentals lecture 1
REHAN IJAZ
 
Basics of c++ Programming Language
Basics of c++ Programming LanguageBasics of c++ Programming Language
Basics of c++ Programming Language
Ahmad Idrees
 
Programming Paradigm & Languages
Programming Paradigm & LanguagesProgramming Paradigm & Languages
Programming Paradigm & Languages
Gaditek
 
Basic programming concepts
Basic programming conceptsBasic programming concepts
Basic programming concepts
salmankhan570
 
Intro To Programming Concepts
Intro To Programming ConceptsIntro To Programming Concepts
Intro To Programming Concepts
Jussi Pohjolainen
 
Programming Languages / Translators
Programming Languages / TranslatorsProgramming Languages / Translators
Programming Languages / Translators
Project Student
 
Programming languages
Programming languagesProgramming languages
Programming languages
Asmasum
 
introduction to programming languages
introduction to programming languagesintroduction to programming languages
introduction to programming languages
NaqashAhmad14
 
PPS UNIT 1- R18.docx
PPS UNIT 1- R18.docxPPS UNIT 1- R18.docx
PPS UNIT 1- R18.docx
Uzma1102
 
Introduction to Problem Solving Techniques- Python
Introduction to Problem Solving Techniques- PythonIntroduction to Problem Solving Techniques- Python
Introduction to Problem Solving Techniques- Python
PriyankaC44
 
Generations Of Programming Languages
Generations Of Programming LanguagesGenerations Of Programming Languages
Generations Of Programming Languages
py7rjs
 
Chapter 1 - An Introduction to Programming
Chapter 1 - An Introduction to ProgrammingChapter 1 - An Introduction to Programming
Chapter 1 - An Introduction to Programming
mshellman
 
Introduction to programming
Introduction to programmingIntroduction to programming
Introduction to programming
Neeru Mittal
 
Programming Fundamentals lecture 1
Programming Fundamentals lecture 1Programming Fundamentals lecture 1
Programming Fundamentals lecture 1
REHAN IJAZ
 

Similar to Programming in C (20)

Programming in C & Decision Making Branching
Programming in C & Decision Making BranchingProgramming in C & Decision Making Branching
Programming in C & Decision Making Branching
VishnuPriya810389
 
Programming in C and Decision Making Branching
Programming in C and Decision Making BranchingProgramming in C and Decision Making Branching
Programming in C and Decision Making Branching
Rvishnupriya2
 
C.pdf
C.pdfC.pdf
C.pdf
5reality786
 
Fundamental of Information Technology - UNIT 7
Fundamental of Information Technology - UNIT 7Fundamental of Information Technology - UNIT 7
Fundamental of Information Technology - UNIT 7
Shipra Swati
 
INTRODUCTION TO C PROGRAMMING MATERIAL.pdf
INTRODUCTION TO C PROGRAMMING MATERIAL.pdfINTRODUCTION TO C PROGRAMMING MATERIAL.pdf
INTRODUCTION TO C PROGRAMMING MATERIAL.pdf
Subramanyambharathis
 
C lecture notes new
C lecture notes newC lecture notes new
C lecture notes new
Kuntal Bhowmick
 
Programming in c
Programming in cProgramming in c
Programming in c
ankitjain851
 
Unit 1
Unit 1Unit 1
Unit 1
TPLatchoumi
 
Learn C Language
Learn C LanguageLearn C Language
Learn C Language
Kindle World..!
 
CS3251-_PIC
CS3251-_PICCS3251-_PIC
CS3251-_PIC
AALIM MUHAMMED SALEGH COLLEGE OF ENGINEERING
 
C programming
C programming C programming
C programming
Rohan Gajre
 
Introduction to Computer
Introduction to ComputerIntroduction to Computer
Introduction to Computer
zaheeriqbal41
 
Introduction to programming c
Introduction to programming cIntroduction to programming c
Introduction to programming c
Md. Rakibuzzaman Khan Pathan
 
Introduction to c language
Introduction to c language Introduction to c language
Introduction to c language
BAKRANIYA KALPESH
 
Best Computer Institute in Pitampura, Delhi, Learn from Industry Experts.
Best Computer Institute in Pitampura, Delhi, Learn from Industry Experts.Best Computer Institute in Pitampura, Delhi, Learn from Industry Experts.
Best Computer Institute in Pitampura, Delhi, Learn from Industry Experts.
Veridical Technologies
 
Ppt 1
Ppt 1Ppt 1
Ppt 1
Mohit Saini
 
Introduction to programming language (basic)
Introduction to programming language (basic)Introduction to programming language (basic)
Introduction to programming language (basic)
nharsh2308
 
UNIT - 1jhjhjbkjhkjhkjhkjhkjhhkkhhh.pptx
UNIT - 1jhjhjbkjhkjhkjhkjhkjhhkkhhh.pptxUNIT - 1jhjhjbkjhkjhkjhkjhkjhhkkhhh.pptx
UNIT - 1jhjhjbkjhkjhkjhkjhkjhhkkhhh.pptx
RoselinLourd
 
Chapter 1 Introduction to C .pptx
Chapter 1 Introduction to C .pptxChapter 1 Introduction to C .pptx
Chapter 1 Introduction to C .pptx
Abdalla536859
 
Intoduction to c language
Intoduction to c languageIntoduction to c language
Intoduction to c language
Student
 
Programming in C & Decision Making Branching
Programming in C & Decision Making BranchingProgramming in C & Decision Making Branching
Programming in C & Decision Making Branching
VishnuPriya810389
 
Programming in C and Decision Making Branching
Programming in C and Decision Making BranchingProgramming in C and Decision Making Branching
Programming in C and Decision Making Branching
Rvishnupriya2
 
Fundamental of Information Technology - UNIT 7
Fundamental of Information Technology - UNIT 7Fundamental of Information Technology - UNIT 7
Fundamental of Information Technology - UNIT 7
Shipra Swati
 
INTRODUCTION TO C PROGRAMMING MATERIAL.pdf
INTRODUCTION TO C PROGRAMMING MATERIAL.pdfINTRODUCTION TO C PROGRAMMING MATERIAL.pdf
INTRODUCTION TO C PROGRAMMING MATERIAL.pdf
Subramanyambharathis
 
Introduction to Computer
Introduction to ComputerIntroduction to Computer
Introduction to Computer
zaheeriqbal41
 
Best Computer Institute in Pitampura, Delhi, Learn from Industry Experts.
Best Computer Institute in Pitampura, Delhi, Learn from Industry Experts.Best Computer Institute in Pitampura, Delhi, Learn from Industry Experts.
Best Computer Institute in Pitampura, Delhi, Learn from Industry Experts.
Veridical Technologies
 
Introduction to programming language (basic)
Introduction to programming language (basic)Introduction to programming language (basic)
Introduction to programming language (basic)
nharsh2308
 
UNIT - 1jhjhjbkjhkjhkjhkjhkjhhkkhhh.pptx
UNIT - 1jhjhjbkjhkjhkjhkjhkjhhkkhhh.pptxUNIT - 1jhjhjbkjhkjhkjhkjhkjhhkkhhh.pptx
UNIT - 1jhjhjbkjhkjhkjhkjhkjhhkkhhh.pptx
RoselinLourd
 
Chapter 1 Introduction to C .pptx
Chapter 1 Introduction to C .pptxChapter 1 Introduction to C .pptx
Chapter 1 Introduction to C .pptx
Abdalla536859
 
Intoduction to c language
Intoduction to c languageIntoduction to c language
Intoduction to c language
Student
 
Ad

More from Rvishnupriya2 (10)

Heaps in Data Structure binary tree concepts
Heaps in Data Structure binary tree conceptsHeaps in Data Structure binary tree concepts
Heaps in Data Structure binary tree concepts
Rvishnupriya2
 
Data Structures and Algorithms are function in various method
Data Structures and Algorithms are function in various methodData Structures and Algorithms are function in various method
Data Structures and Algorithms are function in various method
Rvishnupriya2
 
Advanced Software Engineering.ppt
Advanced Software Engineering.pptAdvanced Software Engineering.ppt
Advanced Software Engineering.ppt
Rvishnupriya2
 
Cluster Analysis.pptx
Cluster Analysis.pptxCluster Analysis.pptx
Cluster Analysis.pptx
Rvishnupriya2
 
Data Mining.ppt
Data Mining.pptData Mining.ppt
Data Mining.ppt
Rvishnupriya2
 
Data Mining Concepts and Techniques.ppt
Data Mining Concepts and Techniques.pptData Mining Concepts and Techniques.ppt
Data Mining Concepts and Techniques.ppt
Rvishnupriya2
 
Data Mining Concepts and Techniques.ppt
Data Mining Concepts and Techniques.pptData Mining Concepts and Techniques.ppt
Data Mining Concepts and Techniques.ppt
Rvishnupriya2
 
Rdbms
Rdbms Rdbms
Rdbms
Rvishnupriya2
 
Computer architecture
Computer architectureComputer architecture
Computer architecture
Rvishnupriya2
 
Computer organization
Computer organizationComputer organization
Computer organization
Rvishnupriya2
 
Heaps in Data Structure binary tree concepts
Heaps in Data Structure binary tree conceptsHeaps in Data Structure binary tree concepts
Heaps in Data Structure binary tree concepts
Rvishnupriya2
 
Data Structures and Algorithms are function in various method
Data Structures and Algorithms are function in various methodData Structures and Algorithms are function in various method
Data Structures and Algorithms are function in various method
Rvishnupriya2
 
Advanced Software Engineering.ppt
Advanced Software Engineering.pptAdvanced Software Engineering.ppt
Advanced Software Engineering.ppt
Rvishnupriya2
 
Cluster Analysis.pptx
Cluster Analysis.pptxCluster Analysis.pptx
Cluster Analysis.pptx
Rvishnupriya2
 
Data Mining Concepts and Techniques.ppt
Data Mining Concepts and Techniques.pptData Mining Concepts and Techniques.ppt
Data Mining Concepts and Techniques.ppt
Rvishnupriya2
 
Data Mining Concepts and Techniques.ppt
Data Mining Concepts and Techniques.pptData Mining Concepts and Techniques.ppt
Data Mining Concepts and Techniques.ppt
Rvishnupriya2
 
Computer architecture
Computer architectureComputer architecture
Computer architecture
Rvishnupriya2
 
Computer organization
Computer organizationComputer organization
Computer organization
Rvishnupriya2
 
Ad

Recently uploaded (20)

ppt untuk seminar proposal dan persiapannya
ppt untuk seminar proposal dan persiapannyappt untuk seminar proposal dan persiapannya
ppt untuk seminar proposal dan persiapannya
Rasidinmamakidin
 
the-importance-of-learning-french-140722055824-phpapp01.ppt
the-importance-of-learning-french-140722055824-phpapp01.pptthe-importance-of-learning-french-140722055824-phpapp01.ppt
the-importance-of-learning-french-140722055824-phpapp01.ppt
LipicaJasujaWadhwa
 
Mutation-Breeding (1).pdf.pptxcoucy9f9yf69f9
Mutation-Breeding (1).pdf.pptxcoucy9f9yf69f9Mutation-Breeding (1).pdf.pptxcoucy9f9yf69f9
Mutation-Breeding (1).pdf.pptxcoucy9f9yf69f9
hkrishna9495
 
Linepro - Product Profile- Capacitive Panels
Linepro - Product Profile- Capacitive PanelsLinepro - Product Profile- Capacitive Panels
Linepro - Product Profile- Capacitive Panels
PaulMalpan1
 
>parallel desktop Crack Latest Free 2025 | PPT
>parallel desktop Crack Latest Free 2025 | PPT>parallel desktop Crack Latest Free 2025 | PPT
>parallel desktop Crack Latest Free 2025 | PPT
yousfhashmi786
 
Download Capcut Pro 5.7.1.2152 Crack Latest Version | PPT
Download Capcut Pro 5.7.1.2152 Crack Latest Version | PPTDownload Capcut Pro 5.7.1.2152 Crack Latest Version | PPT
Download Capcut Pro 5.7.1.2152 Crack Latest Version | PPT
yousfhashmi786
 
ADRENAL CORTbsbsbshEX 3 & 4 - 22MBBS.pptx
ADRENAL CORTbsbsbshEX 3 & 4 - 22MBBS.pptxADRENAL CORTbsbsbshEX 3 & 4 - 22MBBS.pptx
ADRENAL CORTbsbsbshEX 3 & 4 - 22MBBS.pptx
c2422429
 
TabulationwjsnnanamamamNananaka of Data.pptx
TabulationwjsnnanamamamNananaka of Data.pptxTabulationwjsnnanamamamNananaka of Data.pptx
TabulationwjsnnanamamamNananaka of Data.pptx
sriyansh4443
 
Introduction-to-Robotics-PowerPoint-Presentation-on-Robotics (1).ppt
Introduction-to-Robotics-PowerPoint-Presentation-on-Robotics (1).pptIntroduction-to-Robotics-PowerPoint-Presentation-on-Robotics (1).ppt
Introduction-to-Robotics-PowerPoint-Presentation-on-Robotics (1).ppt
AshaManjhi
 
Oxygen Concentrators | Medical Machine Equipment
Oxygen Concentrators | Medical Machine EquipmentOxygen Concentrators | Medical Machine Equipment
Oxygen Concentrators | Medical Machine Equipment
blueredblue74
 
Autodesk AutoCAD Map 3D Crack Free Download Latest Version 2025
Autodesk AutoCAD Map 3D Crack Free Download Latest Version 2025Autodesk AutoCAD Map 3D Crack Free Download Latest Version 2025
Autodesk AutoCAD Map 3D Crack Free Download Latest Version 2025
usmankhan66g66
 
Computer Hardware using mostly in daily.
Computer Hardware using mostly in daily.Computer Hardware using mostly in daily.
Computer Hardware using mostly in daily.
manshajunaid205
 
pharmacology.pdffffffffffffffffffffffffff
pharmacology.pdffffffffffffffffffffffffffpharmacology.pdffffffffffffffffffffffffff
pharmacology.pdffffffffffffffffffffffffff
anooshaazam312
 
Spectrophotometer instrument basics -.pptx
Spectrophotometer instrument basics -.pptxSpectrophotometer instrument basics -.pptx
Spectrophotometer instrument basics -.pptx
muthulakshmitc
 
High Perfomance and Reliability Inverter
High Perfomance and Reliability InverterHigh Perfomance and Reliability Inverter
High Perfomance and Reliability Inverter
CarlosFranco13613
 
Adobe Illustrator CC Crack Version 2025?
Adobe Illustrator CC Crack Version 2025?Adobe Illustrator CC Crack Version 2025?
Adobe Illustrator CC Crack Version 2025?
yousfhashmi786
 
Ashampoo Photo Commander Crack Download (Latest New Version 2025)
Ashampoo Photo Commander Crack Download (Latest New Version 2025)Ashampoo Photo Commander Crack Download (Latest New Version 2025)
Ashampoo Photo Commander Crack Download (Latest New Version 2025)
usmankhan66g66
 
Biology SBK10.pdffgguhjjjjghjtrdrettdryttrdtr
Biology SBK10.pdffgguhjjjjghjtrdrettdryttrdtrBiology SBK10.pdffgguhjjjjghjtrdrettdryttrdtr
Biology SBK10.pdffgguhjjjjghjtrdrettdryttrdtr
abayamargaug
 
Bone Tubeoudgkaitaurauraurarhafhau4rculosis.pptx
Bone   Tubeoudgkaitaurauraurarhafhau4rculosis.pptxBone   Tubeoudgkaitaurauraurarhafhau4rculosis.pptx
Bone Tubeoudgkaitaurauraurarhafhau4rculosis.pptx
gaisga4er
 
荷兰代尔夫特理工大学毕业证书文凭定制TUDelft成绩单定制
荷兰代尔夫特理工大学毕业证书文凭定制TUDelft成绩单定制荷兰代尔夫特理工大学毕业证书文凭定制TUDelft成绩单定制
荷兰代尔夫特理工大学毕业证书文凭定制TUDelft成绩单定制
Taqyea
 
ppt untuk seminar proposal dan persiapannya
ppt untuk seminar proposal dan persiapannyappt untuk seminar proposal dan persiapannya
ppt untuk seminar proposal dan persiapannya
Rasidinmamakidin
 
the-importance-of-learning-french-140722055824-phpapp01.ppt
the-importance-of-learning-french-140722055824-phpapp01.pptthe-importance-of-learning-french-140722055824-phpapp01.ppt
the-importance-of-learning-french-140722055824-phpapp01.ppt
LipicaJasujaWadhwa
 
Mutation-Breeding (1).pdf.pptxcoucy9f9yf69f9
Mutation-Breeding (1).pdf.pptxcoucy9f9yf69f9Mutation-Breeding (1).pdf.pptxcoucy9f9yf69f9
Mutation-Breeding (1).pdf.pptxcoucy9f9yf69f9
hkrishna9495
 
Linepro - Product Profile- Capacitive Panels
Linepro - Product Profile- Capacitive PanelsLinepro - Product Profile- Capacitive Panels
Linepro - Product Profile- Capacitive Panels
PaulMalpan1
 
>parallel desktop Crack Latest Free 2025 | PPT
>parallel desktop Crack Latest Free 2025 | PPT>parallel desktop Crack Latest Free 2025 | PPT
>parallel desktop Crack Latest Free 2025 | PPT
yousfhashmi786
 
Download Capcut Pro 5.7.1.2152 Crack Latest Version | PPT
Download Capcut Pro 5.7.1.2152 Crack Latest Version | PPTDownload Capcut Pro 5.7.1.2152 Crack Latest Version | PPT
Download Capcut Pro 5.7.1.2152 Crack Latest Version | PPT
yousfhashmi786
 
ADRENAL CORTbsbsbshEX 3 & 4 - 22MBBS.pptx
ADRENAL CORTbsbsbshEX 3 & 4 - 22MBBS.pptxADRENAL CORTbsbsbshEX 3 & 4 - 22MBBS.pptx
ADRENAL CORTbsbsbshEX 3 & 4 - 22MBBS.pptx
c2422429
 
TabulationwjsnnanamamamNananaka of Data.pptx
TabulationwjsnnanamamamNananaka of Data.pptxTabulationwjsnnanamamamNananaka of Data.pptx
TabulationwjsnnanamamamNananaka of Data.pptx
sriyansh4443
 
Introduction-to-Robotics-PowerPoint-Presentation-on-Robotics (1).ppt
Introduction-to-Robotics-PowerPoint-Presentation-on-Robotics (1).pptIntroduction-to-Robotics-PowerPoint-Presentation-on-Robotics (1).ppt
Introduction-to-Robotics-PowerPoint-Presentation-on-Robotics (1).ppt
AshaManjhi
 
Oxygen Concentrators | Medical Machine Equipment
Oxygen Concentrators | Medical Machine EquipmentOxygen Concentrators | Medical Machine Equipment
Oxygen Concentrators | Medical Machine Equipment
blueredblue74
 
Autodesk AutoCAD Map 3D Crack Free Download Latest Version 2025
Autodesk AutoCAD Map 3D Crack Free Download Latest Version 2025Autodesk AutoCAD Map 3D Crack Free Download Latest Version 2025
Autodesk AutoCAD Map 3D Crack Free Download Latest Version 2025
usmankhan66g66
 
Computer Hardware using mostly in daily.
Computer Hardware using mostly in daily.Computer Hardware using mostly in daily.
Computer Hardware using mostly in daily.
manshajunaid205
 
pharmacology.pdffffffffffffffffffffffffff
pharmacology.pdffffffffffffffffffffffffffpharmacology.pdffffffffffffffffffffffffff
pharmacology.pdffffffffffffffffffffffffff
anooshaazam312
 
Spectrophotometer instrument basics -.pptx
Spectrophotometer instrument basics -.pptxSpectrophotometer instrument basics -.pptx
Spectrophotometer instrument basics -.pptx
muthulakshmitc
 
High Perfomance and Reliability Inverter
High Perfomance and Reliability InverterHigh Perfomance and Reliability Inverter
High Perfomance and Reliability Inverter
CarlosFranco13613
 
Adobe Illustrator CC Crack Version 2025?
Adobe Illustrator CC Crack Version 2025?Adobe Illustrator CC Crack Version 2025?
Adobe Illustrator CC Crack Version 2025?
yousfhashmi786
 
Ashampoo Photo Commander Crack Download (Latest New Version 2025)
Ashampoo Photo Commander Crack Download (Latest New Version 2025)Ashampoo Photo Commander Crack Download (Latest New Version 2025)
Ashampoo Photo Commander Crack Download (Latest New Version 2025)
usmankhan66g66
 
Biology SBK10.pdffgguhjjjjghjtrdrettdryttrdtr
Biology SBK10.pdffgguhjjjjghjtrdrettdryttrdtrBiology SBK10.pdffgguhjjjjghjtrdrettdryttrdtr
Biology SBK10.pdffgguhjjjjghjtrdrettdryttrdtr
abayamargaug
 
Bone Tubeoudgkaitaurauraurarhafhau4rculosis.pptx
Bone   Tubeoudgkaitaurauraurarhafhau4rculosis.pptxBone   Tubeoudgkaitaurauraurarhafhau4rculosis.pptx
Bone Tubeoudgkaitaurauraurarhafhau4rculosis.pptx
gaisga4er
 
荷兰代尔夫特理工大学毕业证书文凭定制TUDelft成绩单定制
荷兰代尔夫特理工大学毕业证书文凭定制TUDelft成绩单定制荷兰代尔夫特理工大学毕业证书文凭定制TUDelft成绩单定制
荷兰代尔夫特理工大学毕业证书文凭定制TUDelft成绩单定制
Taqyea
 

Programming in C

  • 1. 1
  • 2. 2 • C programming language was developed in 1972 by Dennis Ritchie at bell laboratories of AT&T (American Telephone & Telegraph), located in the U.S.A.. • It was initially designed for programming in UNIX operating system. • Now the software tool as well as the C compiler is written in C. Major parts of popular operating systems like Windows, UNIX, Linux is still written in C.
  • 3. 3 • C is one of the most popular languages used today. • C is a robust programming with an impressive set of built-in functions and a variety of operators which you can use to write any complex program. • C programs are fast and efficient. This is because C uses a powerful set of data types and operators. • C combines the power and capability of assembly language with the user friendly features of a high-level language. • C is the most widely used older programming language. It continues to go strong while older programming languages such as BASIC and COBOL have been virtually forgotten. • C is very much portable, which means programs written on a machine using C can be used on other machines as well without any modification. • A C program consists of a number of functions that are supported by C library. In fact, you can create your own function, which can then be added to the C library.
  • 4. 4 • C is a General Purpose Programming Language. This means C can be used to write a variety of applications. It is often referred to as a “system programming language.” • C is a middle level language, which means it combines the features of high level language with the functionality of an assembly language. • C is a structured programming language, which means as a programmer, you are required to divide a problem into a several different modules or functions. • C is renowned for its simplicity and is easy to use because of its structured approach. It has a vast collection of keywords, operators, built- in functions and data types which make it efficient and powerful. • C is portable, which means a C program runs in different environments. C compilers are available for all operating systems and hardware platforms. Additionally, you can easily write code on one system and port it to another. • C is popular not just because it can be used as a standalone programming language, but also as it can be used as an interface to other more visual languages.
  • 5. 5 • C is a very flexible language; it is convenient and portable, like a high level language and flexible like a low level language. It can be interfaced with other programming languages. • C is super fast. The compilation and execution of programs is much faster on C than with most other languages. • C is modular, which means C programs can be divided into small modules, which are much easier to understand. • C is easily available. The C software is easy to access and can be easily installed on your computer. The installation of C hardly takes a few minutes. • C is easy to debug. The C compiler detects syntax errors quickly and easily and displays the errors along with the line numbers of the code and the error message. • C makes available a number of in-built memory management functions that save memory and improve the efficiency of the program such as malloc(), calloc() and alloc(). • Recursion is one of the common techniques used in C, where in a function calls itself again and again. • Finally, C has a rich set of library functions and supports graphic programming too.
  • 6. Learning C is easier. Instead of straight-away learning how to write programs, we must first know what alphabets, numbers and special symbols are used in C, then how using them constants, variables and keywords are constructed, and finally how are these combined to form an instruction. A group of instructions would be combined later on to form a program. a computer program is just a collection of the instructions necessary to solve a specific problem. The basic operations of a computer system form what is known as the computer’s instruction set. And the approach or method that is used to solve the problem is known as an algorithm. 6
  • 7. 7 • In machine level language computer only understand digital numbers i.e. in the form of 0 and 1. So, instruction given to the computer is in the form binary digit, which is difficult to implement instruction in binary code • The assembly language is on other hand modified version of machine level language. Where instructions are given in English like word as ADD, SUM, MOV etc. It is easy to write and understand but not understand by the machine. • High level languages are machine independent, means it is portable. The language in this category is Pascal, Cobol, Fortran etc. High level languages are understood by the machine. So it need to translate by the translator into machine level. A translator is software which is used to translate high level language as well as low level language in to machine level language
  • 8. 8 Compiler and interpreter are used to convert the high level language into machine level language. The program written in high level language is known as source program and the corresponding machine level language program is called as object program. Both compiler and interpreter perform the same task but there working is different. Compiler read the program at-a-time and searches the error and lists them. If the program is error free then it is converted into object program. When program size is large then compiler is preferred. Whereas interpreter read only one line of the source code and convert it to object code. If it check error, statement by statement and hence of take more time.
  • 9. 9 C Comments It indicates the purpose of the program. It is represented as / * … … … … … … … … … … …. . * / Comment line is used for increasing the readability of the program. It is useful in explaining the program and generally used for documentation. It is enclosed within the decimeters. Comment line can be single or multiple line but should not be nested. It can be anywhere in the program except inside string constant & character constant. Preprocessor Directive: #include<stdio.h> tells the compiler to include information about the standard input/output library. It is also used in symbolic constant such as #define PI 3.14(value). The stdio.h (standard input output header file) contains definition &declaration of system defined function such as printf( ), scanf( ), pow( ) etc. Generally printf() function used to display and scanf() function used to read value
  • 10. 10
  • 11. Main function is the entry point of any C Program. It is the point from where the execution of program is started 11
  • 12. 12
  • 13. 13
  • 14. 14
  • 15. 15
  • 16. 16
  • 17. 17
  • 18. 18
  • 19. 19
  • 20. 20
  • 21. 21
  • 22. 22
  • 23. 23
  • 24. 24 A switch statement tests the value of a variable and compares it with multiple cases. Once the case match is found, a block of statements associated with that particular case is executed. The default case is an optional one. Whenever the value of test- expression is not matched with any of the cases inside the switch, then the default will be executed. Otherwise, it is not necessary to write default in the switch.
  • 25. 25 In computer programming, a loop is a sequence of instructions that is repeated until a certain condition is reached. There are mainly two types of loops: Entry Controlled loops: In this type of loops the test condition is tested before entering the loop body. Loop and While Loops are entry controlled loops. Exit Controlled Loops: In this type of loops the test condition is tested or evaluated at the end of loop body. Therefore, the loop body will execute at least once, irrespective of whether the test condition is true or false. do – while loop is exit controlled loop.
  • 26. 26
  • 27. 27
  • 28. 28