I would like to have a string but it will only accept input as one word i know this is a simple problem but can someone help?
i have so far in this section
#include <string>
string note="";
cin>> note;
cout << note << endl;
all of these are in seperate sections
i dont want to change what the program does based on their input i want it to be a note that they can see whenever they write 3 my menu choice to notes
but thanks i want my string to hold maybe a whole paragraph.
Showing a note would be changing what it does wouldn't it?
I think the if statement still stands. If you have a whole paragraph of exact input, you can still get it the same way as above. The else was optional.
uhm, having reread your question, I may have totally answered the wrong thing. Were you just worried about getting longer input? for that you could use cin.get
cin.ignore(80, '\n'); //clear buffer
cin.get(note, 800); //allows an 800 character input
cin.ignore(80, '\n'); //clear buffer