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?