Nov 26, 2013 at 5:55pm
I already know that but cin.ignore() normally works.
Nov 26, 2013 at 6:28pm
You have declared variable "name" as type int, you may want to change that to string. [you will need #include <stream>]
If you want user to be able to enter first and last name then use getline () instead of cin.
You also have typo in one of your variable names. It should be "answer" not "awnser".
Nov 26, 2013 at 10:52pm
RabMac String is under #include <string>
not stream.
Nov 27, 2013 at 11:53am
Well thanks for the info on the string part
but its still closing!
Nov 27, 2013 at 1:15pm
Yeah I meant <string> gibilit ;)
Instead of using cin use getline ()
Nov 27, 2013 at 1:48pm
@RabMac
getline ()
is not working
"getline is undefined"
Nov 27, 2013 at 4:43pm
std::getline( std::cin , string_goes_here );
Nov 27, 2013 at 5:29pm
that did not work but I figured something out!
when it closing I can only see a not amy
so I typed in a and that worked
but when I type in a full name it just closes.