摘要: 242. 有效的字母异位词 如果长度不同则肯定为false 声明长度为26的数组,如果s中出现则对应位置+1,t中出现则-1,最后遍历数组,如果都是0则返回true,否则false 1 class Solution { 2 public: 3 bool isAnagram(string s, str 阅读全文