Results 1 to 2 of 2
Code:
#include <iostream>
int main()
{
cout << "Helllo, have fun with C++" ;
return(0);
}
the program is named "first.cc"
compiled the program with C++ first.cc
Following were the ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
- 09-10-2003 #1Just Joined!
- Join Date
- Sep 2003
- Location
- Bangkok
- Posts
- 2
C++ configuring (error attached ) pls help
the program is named "first.cc"Code:#include <iostream> int main() { cout << "Helllo, have fun with C++" ; return(0); }
compiled the program with C++ first.cc
Following were the errors
C++ first.cc
first.cc : In function int main()':
first.cc:4: 'cout' undeclared (first use this function)
first.cc:4
Each undeclared identifier is reported only once for each function it appears in.)
- 09-10-2003 #2Linux Engineer
- Join Date
- Nov 2002
- Location
- Queens, NY
- Posts
- 1,319
What compiler version are you running? I'm guessing that it's above gcc2.95. Try this instead:
If you want an explanation, please ask for one. I'm rather tired at this time but I will explain it tomorrow or so if asked.Code:#include <iostream> using namespace std; int main() { cout << "Hello Bankok!!\n"; // Question, does return(0) work? return 0; }
The best things in life are free.


Reply With Quote
