I’m trying to make a simple program with user input, but std::cin is not working. The std::cout commands are working properly, but they both execute without giving me a chance to input anything. I’ve checked my code repeatedly, but I can’t see a problem. Here is my code:
#include
int main()
{
std::string words;
std::cout << "Enter action: ";
std::cin >> words;
std::cout << "\nYou have chosen to " << words << “.”;
}