Can someone look at this program and tell me why i am getting the error that
**c:\documents and settings\burley\desktop\carrie\cpp1.cpp(26) : error C2664: 'substr' : cannot convert parameter 2 from 'class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> >' to 'unsigned int'
here is the program!!!!
#include <iostream>
#include <string>
using namespace std;
int main ()
{
string fullname;
cout<< "Please enter you first and last name:";
cin>>fullname;
getline(cin,fullname,'\n');
string spaceposition;
spaceposition= fullname.find(" ",0);
string fname;
fname=fullname.substr(0,spaceposition);
string lname;
lname=fullname.substr(spaceposition,fname.size());
cout << "First Name: "<<fname<< endl;
cout << "Last Name: " <<lname<< endl;
return 0;
} ///Thank you !!!!!