Tsubasa
March 2nd, 2006, 10:27 AM
Hi
I've just started programming in C++ today and I'm already encounting a problem. Well when trying to create a simple program to reading a string a output it, there's a lot of errors. Here is my program:
#include <iostream.h>
#include <string.h>
using namespace std;
int main()
{
cout<<"what is your name?"<<endl;
string first;
cin >> first;
cout<<"hi, "<< first;
return 0;
}
well after compiling it says that std , first and string are undefined indentifirers. Why is it telling me that???
can anyone help me.
I've just started programming in C++ today and I'm already encounting a problem. Well when trying to create a simple program to reading a string a output it, there's a lot of errors. Here is my program:
#include <iostream.h>
#include <string.h>
using namespace std;
int main()
{
cout<<"what is your name?"<<endl;
string first;
cin >> first;
cout<<"hi, "<< first;
return 0;
}
well after compiling it says that std , first and string are undefined indentifirers. Why is it telling me that???
can anyone help me.