summaryrefslogtreecommitdiff
path: root/detect_new.cpp
blob: e5bf80ce64677bcce8395cb1b507739446777e79 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#include <set>
#include <string>
#include <iostream>

using namespace std;

int main() {
  set<string> known;
  string i;
  for (getline(cin, i); cin.good(); getline(cin, i)) {
    if (known.count(i)) {
      cout << "0" << endl;
    }else{
      known.insert(i);
      cout << "1" << endl;
    }
  }
  return 0;
}
contact: Jan Huwald // Impressum