C programming tutorial

C is a high-level procedure-oriented structured programming language. C support module or function so it is called as procedure oriented language.

Top down approach in the form of blocks is called a structured programming language.

"C" is easy to learn and understand.

Application of C

"C" programming language can be used for different kind of application such as

System software development

Example :Operating system and compiler.

Application software development

Example : database and excel sheet.

Graphics related application

Example: PC and Mobile games


About this tutorial

In this "C" tutorial basically, we provide different C programs that helps a beginner to write C program easily and create a C project of his own.


In the year of 1972, Dennis Ritchie has developed "C" programming language at AT and T Bell laboratories for developing system software.

Hello World Example

let's start with a simple Hello program.


# include <stdio.h>
# include <conio.h>
int main()
return 0;

Description Of Hello World Example

The stdio.h is a header file which provide standard input output library function like printf(), scanf() etc. To use the file, we need to include it in our program using #include preprocessor.

The main() function

In C code execution begins from main() function ( put main() function anywhere in the program ).

The code inside the curly braces { } is the body of main() function. The main() function is mandatory in C program.

int main()

This program doesn’t do anything but, it’s a valid C program.

The printf() function

The printf() is a library function that sends formatted output to the screen (displays the string inside the quotation mark). semicolon at the end of the statement is mondatory.

In our program, it displays Hello, World! on the screen.

Remember, we need to include stdio.h file in your program for this to work.

The return statement

Every function in c return the value and main() is also a function so it returns the value.therefore we have to write return statement but if we put void return type then no need to write return statement.

Connection failed: SQLSTATE[28000] [1045] Access denied for user 'studentdb'@'localhost' (using password: YES)