D_L3

Dundee The Crocodile

Jan 27th, 2024
802
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.37 KB | None | 0 0
  1. #include <cmath>
  2. #include <cstdio>
  3. #include <vector>
  4. #include <iostream>
  5. #include <algorithm>
  6. #include <map>
  7.  
  8. using namespace std;
  9.  
  10.  
  11. int main() {
  12.     map<string, int> words;
  13.     string word;
  14.     while(cin >> word){
  15.         words[word]++;
  16.     }
  17.     for(auto wordPair : words){
  18.         if(wordPair.second == 1)
  19.             cout << wordPair.first << endl;
  20.     }
  21. }
  22.  
Advertisement
Add Comment
Please, Sign In to add comment