Thread: Dev c++
View Single Post
Old Feb 20th, 2005, 9:11 PM   #13
quitter
Newbie
 
quitter's Avatar
 
Join Date: Feb 2005
Posts: 9
Rep Power: 0 quitter is on a distinguished road
Send a message via ICQ to quitter Send a message via AIM to quitter
Quote:
Originally Posted by Dietrich
I agree,
http://www.cplusplus.com/doc/tutorial/index.html
is very thorough from the start on up.

For a book I recommend "Standard C++ Bible" by Al Stevens and Clayton Walnum. It has a CD-ROM with all the sample code from the book and an integrated compiler, so you can run the code and most importantly experiment with it. That's the way to learn!!!

I use that site but wen i compile it and try to run it all it does is cmd opens real fast and closes right away...
i tried what they gave me which was this

Quote:
// my first program in C++

#include <iostream.h>

int main ()
{
cout << "Hello World!";
return 0;
}
which doesnt really work.. i get the error which i explained already, but when i try this one

Quote:
#include <iostream>
using namespace std;
int main()
{
cout << "Hello World!" << endl;
cin.get();
return 0;
}
It works cmd opens and i can read hello world.. can someone explain whats hte difference? what exactly does << endl; do?
__________________
Welcome to the real world...
quitter is offline   Reply With Quote