We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 727acfe commit b5058ddCopy full SHA for b5058dd
0242-valid-anagram/0242-valid-anagram.py
@@ -0,0 +1,8 @@
1
+class Solution(object):
2
+ def isAnagram(self, s, t):
3
+ if len(s) != len(t):
4
+ return False
5
+ for idx in set(s):
6
+ if s.count(idx) != t.count(idx):
7
8
+ return True
0 commit comments