二十九号的。。。
Given two strings s and t, write a function to determine if t is an anagram of s.
For example,
s = "anagram", t = "nagaram", return true.
s = "rat", t = "car", return false.
class Solution {
public:
bool isAnagram(string s, string t) {
int l=t.length();
int ll=s.length();
if(l!=ll) return false;
int num[30];
memset(num,0,sizeof(num));
for(int i=0;i<l;i++)
{
num[s[i]-'a']++;
}
for(int i=0;i<l;i++)
{
num[t[i]-'a']--;
if(num[t[i]-'a']<0) return false;
}
return true;
}
};