Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <sstream>
- #include <string>
- #include <string.h>
- #include <algorithm>
- #include <vector>
- using namespace std;
- int main()
- {
- string inPut;
- getline(cin,inPut);
- istringstream ss(inPut);
- string word;
- vector<string> vec;
- while(ss >> word)
- {
- string remove_number = "";
- for (char c : word)
- {
- if (!std::isdigit(c))
- {
- remove_number += c;
- }
- }
- if(remove_number.size() > 0)
- {
- vec.push_back(remove_number);
- }
- }
- sort( vec.begin(), vec.end());
- if(vec.size() == 0)
- {
- cout<<"no noise";
- }
- else
- {
- //for(int i =0; i < vec.size(); i ++)
- cout<<vec[0];
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement