class Solution {
public:
/**
* @param s: The first string
* @param b: The second string
* @return true or false
*/
bool anagram(string s, string t) {
// write your code here
map<char,int> m1,m2;
for(auto c:s){
m1[c]++;
}
for(auto b:t){
m2[b]++;
}
for(auto a:m1){
if(m1[a.first]!=m2[a.first])
return false;
}
return true;
}
};