Cod sursa(job #1263172)
| Utilizator | Data | 13 noiembrie 2014 23:56:30 | |
|---|---|---|---|
| Problema | Restante | Scor | 100 |
| Compilator | cpp | Status | done |
| Runda | Arhiva de probleme | Marime | 0.49 kb |
#include <fstream>
#include <algorithm>
#include <map>
int main ()
{
std::ifstream fin("restante.in");
std::ofstream fout("restante.out");
std::map<std::string,int> count;
int n;
fin>>n;
std::string s;
for(int i=0;i<n;i++)
{
fin>>s;
std::sort(s.begin(), s.end());
count[s]++;
}
int total = 0;
for (auto& e: count)
{
if(e.second == 1)
{
total+=1;
}
}
fout<<total;
return 0;
}
