Learn C programming
Mohd Vais
Presented by:
What is language
If we talk about the language, any type of language so an idea is come in your mind which
is, anything which we think and we can express, by language. Or we can say language is a
way of expressing your ideas. C language is same to other natural language (like English)
which we learn. It is also one-way communication, in which computer user communicate
with computer.
History of C language
Before becoming C language, there
was a language Basic Combined
Programming language, (BCPL). It is a
programming language developed by
Martin Richards in 1966. They created
this language by combining many
features of languages.
Ken Thompson improve the BCPL
language and used the first letter of
BCPL language which is known as B
language. And C is also created by
improving B language.
INTRODUCTION TO C LANGUAGE
C language is a medium to interact with computer. The C language was developed by -
“Dennis Ritchie” at the AT&Bell telephone laboratories in 1972. First c language was
developed to write UNIX operating system. It is also made it for easier to move programs
between computer with different hardware. It is more flexible.
The C language was names C because its predecessor was named B. The B language was
developed by “Ken Thompson”.
Most of the software are written in C language and UNIX operating system is also written in C
because of these reasons-
* Easy to learn
* Structured language
* It produces efficient program
* It can handle low-level activities
* It can be compiled on a variety of computer platform
Structure of C programs
 Before going to learn the structure of c programs first we need to have some basic
knowledge of the following:
 C’s character set
 Keywords
 Data types
 Variables
 function
// Name of program Documentation section
#include<stdio.h> link section
#include<conio.h>
#define max Definition section
void add(); Global declaration section
int x=10;
int main() main () function section/entry point
{ int a =10; variable declaration
printf(“Hello main”);
return 0; body of main function
}
void add() {
printf(“Hello add”); function declaration
}
A C program involves the following sections
Simple code of C “hello world” program
// simple hello world C code
#include<stdio.h>
#include<conio.h>
void main()
{
printf("Hello, World!n");
return;
}
Data types
C language supports the following basic data types:
 int: integer, a whole number.
 float: floating point , a number with a functional part.
 double: double –precision floating point value.
 Char: single character.
Data types
Primitive data types

C programming tutorial

  • 1.
    Learn C programming MohdVais Presented by:
  • 2.
    What is language Ifwe talk about the language, any type of language so an idea is come in your mind which is, anything which we think and we can express, by language. Or we can say language is a way of expressing your ideas. C language is same to other natural language (like English) which we learn. It is also one-way communication, in which computer user communicate with computer.
  • 3.
    History of Clanguage Before becoming C language, there was a language Basic Combined Programming language, (BCPL). It is a programming language developed by Martin Richards in 1966. They created this language by combining many features of languages. Ken Thompson improve the BCPL language and used the first letter of BCPL language which is known as B language. And C is also created by improving B language.
  • 4.
    INTRODUCTION TO CLANGUAGE C language is a medium to interact with computer. The C language was developed by - “Dennis Ritchie” at the AT&Bell telephone laboratories in 1972. First c language was developed to write UNIX operating system. It is also made it for easier to move programs between computer with different hardware. It is more flexible. The C language was names C because its predecessor was named B. The B language was developed by “Ken Thompson”. Most of the software are written in C language and UNIX operating system is also written in C because of these reasons- * Easy to learn * Structured language * It produces efficient program * It can handle low-level activities * It can be compiled on a variety of computer platform
  • 5.
    Structure of Cprograms  Before going to learn the structure of c programs first we need to have some basic knowledge of the following:  C’s character set  Keywords  Data types  Variables  function
  • 6.
    // Name ofprogram Documentation section #include<stdio.h> link section #include<conio.h> #define max Definition section void add(); Global declaration section int x=10; int main() main () function section/entry point { int a =10; variable declaration printf(“Hello main”); return 0; body of main function } void add() { printf(“Hello add”); function declaration } A C program involves the following sections
  • 7.
    Simple code ofC “hello world” program // simple hello world C code #include<stdio.h> #include<conio.h> void main() { printf("Hello, World!n"); return; }
  • 8.
    Data types C languagesupports the following basic data types:  int: integer, a whole number.  float: floating point , a number with a functional part.  double: double –precision floating point value.  Char: single character.
  • 9.
  • 10.