#include<iostream>
using namespace std;
int main()
{
	string str;
	getline(cin,str);
	
	cout<<str;
	
	
	return 0;
}

利用getline函数

C++中带空格的字符串输入

相关文章:

  • 2022-12-23
  • 2021-08-23
  • 2021-05-28
  • 2021-12-10
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2022-01-09
  • 2021-05-29
  • 2021-12-29
  • 2022-12-23
相关资源
相似解决方案