Hi,

How do I properly put this to code? I am trying to return a string (name) from a function using reference.

Code:
std::string& name()
{
   cout << "Enter your name: " << endl;
   getline(cin, name);
}
I hope you get the idea. Thanks!