Skip to main content

C Language Tutorial


C Programming Language Tutorial     

  What is C Programming                            
C Language is most popular and widely used programming language. C language is basic language of all other programming languages so also knows as mother language. that directly interact with the hardware devices like kernel and drivers.

  • C is a Procedural language because solve the programming problem in step by step.  C language  break the program into function.
  • C is a Structured language because break a program into several parts and blocks so that easy to understand this program.and break the program into several parts and blocks using function.
  • C is a Mother language because base for other programming language.C language is also considered a several concepts like function, constructor, pointer etc.
  • C is a Mid -level language bcz consider the feature of low-level and high-level programming language. C support low level language bcz consider pointer arithmetic .C support high level language bcz  it is a machine independent. 
  • C is a System Programming language  bcz used to create system software.C create a hardware device, OS,drivers.

 History Of C Language

                         


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.

Features Of C Programming Language

Features are as follows:-

  • Fast Speed:-  Program execution and compilation time very fast in c language.
  • Simple:- c is a simple language bcz break the programming problem into parts. 
  • Rich library:- C language provide a many inbuilt function.
  •  Structured language:-C is structured programming because break a program into several parts and blocks so that easy to understand this program.and break the program into several parts and blocks using function.
  • Memory Allocation:- C consider a dynamic memory allocation It allocate the memory at run time. DMA function like malloc(), calloc(), realloc(), free(). 
  • Mid-level language:- C is a Mid -level language bcz consider the feature of low-level and high-level programming language. C support low level language bcz consider pointer arithmetic.C support high level language bcz  it is a machine independent.    
  • Platform Dependent:-                                                                  Before you know about Platform Dependent And Independent. We  must  know about Platform.                                                  Platform:-Any hardware or software environment in which a programs runs,is knows as a platform.                                        So C is a Platform Dependent language bcz all programs are run in specific OS(Operating System) like Turbo C.                   
  • Extensible:-C is extensible bcz  it can easily access new feature. 
  • Pointer:- C provide a features of pointer.pointer in C language is a variable stores the address of another pointer variable.
  • Recursion:- It provide a code re usability for all function.and provide the feature of call to itself.
Sample program of C Language.

#include<stdio.h>
#include<conio.h>     
void main()
{
printf("Hai");
return 0;
getch();
}

How to compile and run c program.
 alt+f9 compile the program.
 ctrl+f9 run the program.
 Press Esc key return to the turbo c console.

Explanation Of Above Program.

#:- Denote the preprocessor directive. predefined processor are already define in C library. this is used for define the header file and also used for include the value.
include:-include the all header files in program.

# include<stdio.h> includes the standard input output library functions. printf() function is defined in stdio.h header file.

#include<conio.h> include the console input output library function. getch() function is defined in conio.h header file.

Clrscr(); :- clear the screen

void main():- void keyword specifies that it return no value. main() function is the entry point of every program.

printf():- This function is used to print the data. this is a predefine function of <stdio.h> header file.

scanf():- This function is used for input the value.
this is also a predefine function of <stdio.h> header file. 

return 0:-the return 0 statements returns execution status to the operating system.value 0 is successful execution and value 1 for unsuccessful execution. 

getch():-The getch() function ask for a single character. Until you press any key, it blocks the screen.

Flow Of C program.
           




About figure of compiler

1.Source code:-source code is a typical English language code which is written by programmer.
2. Preprocessor:- Preprocessor that use for translate higher level language in pure high level language.
 3.Compiler:-Compiler that convert source code into object code object code is a code that can execute by compiler.
4.Linker:-Linker use for convert object code in executable code that can stored in memory in machine language.
5.Loader:- Loader is use to load machine language code in memory
6.Assembler:- assembler is also a language interpreter that convert the symbolic language in machinery executable language.

WAITING FOR NEXT TOPIC






















Comments

Post a Comment

Popular posts from this blog

Let's Be Technical

.   Programming Languages And There       Importance       Before you know about programming  language  we  must  know about languages. the language is a communication medium why which we can understand other person the language way of the transformation of various ideas and thoughts among people. After this  now we  know about programming language a programming language is a formal language, which comprises a set of instructions that produce various kinds of output. Programming languages are used in computer programming to implement algorithms. Most programming languages consist of instructions for computers. How its Importance of Programming Language Important in your daily life we use various device & tools that are works one the programming language like microwave ,ATM, Lift etc.  Programming language is important  because it define semantics and grammar which allow the pro...

Rapid View Of Technology

  Currently Running Top 10 Programming Languages C programming language                         C language is the most popular and and widely used programming language.The C language is developed in 1972 by  Dennis Ritchie at bell laboratories of AT&T American Telephone & Telegraph, located in the U.S.A . C language is also knows as mother and structured programming language.C language is a basic language of all other languages. C++ programming language                                 C++ is object oriented programming language. C++ programming language was developed in 1980 by Bjarne Stroustrup  at bell laboratories of AT&T,located in U.S.A  . C++ is totally based on oops concept. HTML                              ...

C Looping Statements

Looping/Iterative Statements What is Loop one statements are executed one or more time .looping simplify the complex problems into the easy one.loop provides code reusability.  we do not need to write same code again and again.looping is used to traverse the element of  data structure. Types of loops 💥 For Loop:- In C the For loop is used to iterate a part of the program many time.In the for loop number of iteration is fixed. Syntax:- for(initialization,condition,increment/decrement) { statement }                                   Flow chart of for loop Example                                                                      #include<stdio.h>    #include<conio.h>...