|
-
Mar 10th, 2009, 12:25 AM
#35
Banned
Re: C/C++ - Hello World (very simple)
 Originally Posted by BeholderOf
Code:
#include <iostream.h>
int main()
{
//This prints "Hello World" and <<endl makes a new line
cout<<"Hello World"<<endl;
return 0;
}
Explaination:
"#include <iostream.h>" - This is the header for cout/cin, in other words we include iostream.h so we can use the functions cout<<, and cin>>.
"int main()" - this is where our program actually starts.
"cout<<"Hello World"<<endl;" - This is what actually prints the text to the screen.
Just a simple example !
This is the basic of c++. Every one know about it...
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|