Program is skipping over Getline() without taking user input [duplicate]
问题 This question already has answers here : Why does std::getline() skip input after a formatted extraction? (3 answers) Closed 5 years ago . This is a very strange problem, when my program asks the user for the address, instead of waiting for input, it seems to skip the getline() function completely Answerinput: cout << "would you like to add another entry to the archive? (Y/N):"; cin >> answer; cout << endl; cout << endl; answer = toupper(answer); switch(answer) { case 'Y': Entrynumber++; cout