C is general purpose programming language developed for using in the Unix operating system.Now many upgraded C versions are available for instance ANSI C ,C#,C++.For a student or a programmer learning this languages are of prime concern.C programming offers extended reliability although it is platform dependent.
So,Lets look into the C programming language ,this blog will be dealing with ANSI C ,C++,C++.
Iam trying to present a new mode of learning in this blog where a small demonstrative program alon with some basic info will be used to explain you the c programming language rather than reading through chunks of material thus making learning process a fast and interesting one.
C language has a vast collection of inbuilt functions which can be used to do lots of important functions eg:printf: Output functions ,scanf:Input functions, we will be dealing with functions later.Lets begin with a simple "hello world" program
___________________________________________________________________
#include
void main()
{
printf("hello world") }
____________________________________________________________________
In the above program print library function is used to display "hello world" .
So,Lets look into the C programming language ,this blog will be dealing with ANSI C ,C++,C++.
Iam trying to present a new mode of learning in this blog where a small demonstrative program alon with some basic info will be used to explain you the c programming language rather than reading through chunks of material thus making learning process a fast and interesting one.
C language has a vast collection of inbuilt functions which can be used to do lots of important functions eg:printf: Output functions ,scanf:Input functions, we will be dealing with functions later.Lets begin with a simple "hello world" program
___________________________________________________________________
#include
void main()
printf("hello world")
Now lets see to the program the first line #include is used to ask the compiler to include
the standard input output function file stdio.h from the Compiler's parent directory.This file file consists of many inbuit functions.in this program we use print function(printf).Although printf is
inbuit function in c language it is good practice to include stdio.h file .
The next line voidmain() is the call for the main function it calls the main function.void keyword says that the main function does not return any value all these you will learn later.Every program in C should have a call to main function.{ brace indicate opening of main function
} brace indicate closing of main function.
The next line printf("hello world") uses print function to diplay the line hello world.This is a beginners program in C.
No comments:
Post a Comment