Cod sursa(job #1811387)
| Utilizator | Data | 21 noiembrie 2016 10:27:37 | |
|---|---|---|---|
| Problema | Restante | Scor | 100 |
| Compilator | cpp | Status | done |
| Runda | Arhiva de probleme | Marime | 0.46 kb |
#include <bits/stdc++.h>
using namespace std;
ifstream f("restante.in");
ofstream g("restante.out");
string cuv[36003];
map <string, int> Mp;
int main()
{
int n, ans = 0;
f >> n;
for(int i = 1; i <= n; i++) {
f>> cuv[i];
sort(cuv[i].begin(),cuv[i].end());
}
for(int i = 1; i <= n; i++)
Mp[cuv[i]]++;
for(int i = 1; i <= n; i++)
if(Mp[cuv[i]] == 1)
ans++;
g << ans;
return 0;
}
