Python 1 line solution


  • 0
    A
    def isAnagram(self, s, t):
        """
        :type s: str
        :type t: str
        :rtype: bool
        """
        return sorted(str(s)) == sorted(str(t))

Log in to reply
 

Looks like your connection to LeetCode Discuss was lost, please wait while we try to reconnect.