📜  获取行 C++ 代码示例

📅  最后修改于: 2022-03-11 14:44:56.684000             🧑  作者: Mango

代码示例2
//getline allows for multi word input including spaces ex. "Jim Barens"
#include 
#include 

int main() 
{
  string namePerson{};     // creating string
  getline(cin, namePerson);// using getline for user input
  std::cout << namePerson; // output string namePerson
}