标签:
题目链接:https://leetcode.com/problems/valid-anagram/
题目: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.
Note:
You may assume the string contains only lowercase alphabets.
解题思路:分别统计s和t的每个字母的个数,如果均相同则为Anagram。
示例代码:
【LeetCode OJ 242】Valid Anagram
标签:
原文地址:http://blog.csdn.net/xujian_2014/article/details/50538784