#include<iostream> #include<stdlib.h>
#include<vector> #include<map> #include<set> (8555)#include<iterator>
#include<string> #include <algorithm>
#include <iostream> #include <vector> using namespace std; void sortString(string& s){ sort(s.begin(),s.end()); } int main() { int n; vector<string> vec; cin >> n; for(int i = 1; i <= n ; ++i){ string s; cin >> s; vec.push_back(s); } map<string> mp; for(auto s : vec){ sortString(s); if(mp.find(s) == mp.end()) mp[s] = 1; else mp[s] += 1; } int res = 0; for(auto iter = mp.begin(); iter != mp.end(); ++iter) res = max(res,iter->second); cout << res << endl; }</string></string></vector></iostream></algorithm></string></iterator></set></map></vector></stdlib.h></iostream>