Hello World!
This is the basic program in any programming language and I want to start my blogging routine with this basic and simple program.
This program doesn't use much of programming skills but tells us how far the technology has reached that a human created machine can respond back to us on the basis of our input. And nowadays computers could also respond physically and sensibly to human action as they are programmed to do so . Programming is a basic term in computers and electronics but it has huge importance and significance if we want to acquire detailed Knowledge in the stream of computer science.
Now Lets come back to our topic,our basic C++ or any other programming language programme, but I will use only c++ for coding as the blog name refers.Now Lets Start:-
#include<iostream>//basic header file containing basic input/output operation functions
using namesspace std;
int main()//the program execution starts here
{
cout << "Hello World" << endl;//displaying output on console
return 0;
}
this is the syntax of a basic "Hello World " program on any modern compiler.Here the program execution means performing the operations listed in program and displaying their output on console.The Program execution takes place only in main as only main function is connected with os and only it can interact with it through the compiler.The int written in the above code is the return type of function main which we will discuss later on.
You could download any ide for coding in c++ like codeblocks,visualc++,turbo c++,etc.
For those using Linux can do it on g++,genny,codeblocks,etc
syntax of above code in turbo c++:-
#include<iostream.h>
#include<conio.h>
int main()
{
clrscr();//to clear the screen
cout<<"Hello World"<<endl;
getch();//to pause the output
return 0;
}
you can also watch the installation video of turbo c++ from https://www.youtube.com/watch?v=bswCJ3M6Dpc and basic hello world program in it https://www.youtube.com/watch?v=-ffLfCiSzsQ.
It is recommended to use any modern compiler like codeblocks or visual c++.
Thanks for Reading and Keep Learning.
This is the basic program in any programming language and I want to start my blogging routine with this basic and simple program.
This program doesn't use much of programming skills but tells us how far the technology has reached that a human created machine can respond back to us on the basis of our input. And nowadays computers could also respond physically and sensibly to human action as they are programmed to do so . Programming is a basic term in computers and electronics but it has huge importance and significance if we want to acquire detailed Knowledge in the stream of computer science.
Now Lets come back to our topic,our basic C++ or any other programming language programme, but I will use only c++ for coding as the blog name refers.Now Lets Start:-
#include<iostream>//basic header file containing basic input/output operation functions
using namesspace std;
int main()//the program execution starts here
{
cout << "Hello World" << endl;//displaying output on console
return 0;
}
this is the syntax of a basic "Hello World " program on any modern compiler.Here the program execution means performing the operations listed in program and displaying their output on console.The Program execution takes place only in main as only main function is connected with os and only it can interact with it through the compiler.The int written in the above code is the return type of function main which we will discuss later on.
You could download any ide for coding in c++ like codeblocks,visualc++,turbo c++,etc.
For those using Linux can do it on g++,genny,codeblocks,etc
syntax of above code in turbo c++:-
#include<iostream.h>
#include<conio.h>
int main()
{
clrscr();//to clear the screen
cout<<"Hello World"<<endl;
getch();//to pause the output
return 0;
}
you can also watch the installation video of turbo c++ from https://www.youtube.com/watch?v=bswCJ3M6Dpc and basic hello world program in it https://www.youtube.com/watch?v=-ffLfCiSzsQ.
It is recommended to use any modern compiler like codeblocks or visual c++.
Thanks for Reading and Keep Learning.
Comments
Post a Comment