Easy learning with example program codes

First C Program

Lets print “Hello C” as the first C program and than understand it in detail.

#include <stdio.h>
void main()
printf ("Hello C!");


Hello C!


#include <stdio.h> :

“#include” is a preprocessor directive used to include a library file in the code. The header file “stdio.h” is included in the source code to use the pre-defined functions “printf” and “scanf”.

 void main() :

Void represents the data type of the main function which is a must for every C program.

 {} :

{} represents the opening and closing of the main function.

printf (“Hello C!”); :

The printf function outputs the string on the console screen.

Compilation and Execution:

Click on Compile menu and then on Run menu or click ctrl+F9 directly, both for compile and run.

Posted in C   

Industrial Training

We offers Placement Oriented Training on Java, Spring, JSF, Hibernate, PHP, AngularJS, Angular 4, PLSQL, Oracle BI Publisher etc. We also provides Online training, please mail us at


We also provides the Development services for Website Development , Java Development, PHP Development, Android App Development etc. You can contact us on

Copyright © 2019 CodesJava Protection Status SiteMap Reference: Java Wiki