Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- int main(int argc, char const *argv[]){
- char sh;
- do{
- cin >> sh;
- if(sh){
- cout << "sex: " << sh << endl;
- }else cout << "Символ не введён!\n";
- }while(sh != 's');
- }
- ./a.out
- \dfhfhdfdfh
- sex: \
- sex: d
- sex: f
- sex: h
- sex: f
- sex: h
- sex: d
- sex: f
- sex: d
- sex: f
- sex: h
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement