Stuck at a point

Posts 1–4 of 4 · Page 1 of 1
Stuck at a point
GOT A PROBLEM

Code:
#include <iostream>
using namespace std;

int main()
{
	cout << "Zhhot rulz at CA";
	return 0;
}
its really annoying me, cuz after i compiled and when i start the exe file, it doesnt last for more than 1 or 2 seconds?!?!

can someone tell me the instructions on what to do?
Add system("pause");
Code:
#include <iostream>
using namespace std;

int main()
{
	cout << "Zhhot rulz at CA";
	return 0;
        system("pause");
}

or cin.get();
Code:
#include <iostream>
using namespace std;

int main()
{
	cout << "Zhhot rulz at CA";
	return 0;
        cin.get();
}
These two lines will become ur best friends :P
Quote Originally Posted by why06 View Post
Add system("pause");
Code:
#include <iostream>
using namespace std;

int main()
{
	cout << "Zhhot rulz at CA";
	return 0;
        system("pause");
}

or cin.get();
Code:
#include <iostream>
using namespace std;

int main()
{
	cout << "Zhhot rulz at CA";
	return 0;
        cin.get();
}
These two lines will become ur best friends :P
Also, for cin.get(); 2 of them are sometimes necessary.
Code:
#include <iostream.h>
using namespace std;

int main()
{
   cout << "Zhhot rulz at CA!\n";
system("pause");
return 0;
}
Thanks, i did it this way and it worked!!!
Posts 1–4 of 4 · Page 1 of 1
This thread is closed for replies.

Similar Threads

Tags for this Thread

Talk with us