本文介绍了如何用空格来整个句子的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我有
char tab[200];
cin>>tab;
cout<<tab<<endl;
我希望即使我在控制台输入 / code>所有3个字符和空格立即进入
标签
。
and i would like to make that even if I input in console
A B C
all the 3 chars and spaces go into tab
at once .
推荐答案
使用:
char tab[200];
cin.getline(input,200);
cout<<tab<<endl;
这篇关于如何用空格来整个句子的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!