If you use getline() after cin >> anything, you must first flush the newline character from the buffer.
You can achieve this by using the cin.ignore()
It would be something like this:
string messageVar;
cout ...READ MORE
Jun 1, 2022
in C++
by
Damon
• 4,960 points
•
1,496 views