--C ++ programming study notes cin test record

cin reads the input stream, encountered a space will pause, next to continue reading the rest, +++.

#include <iostream>

using namespace std;

int main() {
    cout<<"input sth."<<endl;
    char a[20];
    cin >>a;
    cin >>a;
    cout << a << endl;
    return 0;
}

Second full coverage for the first time.

 

 

Guess you like

Origin www.cnblogs.com/wxl845235800/p/11184894.html