✅A very easy python approach.
first condition would be checking that if both are equal without swaping it one time\n\nthen use sorted() method to sort it alphabetically and check if they are
first condition would be checking that if both are equal without swaping it one time\n\nthen use **sorted()** method to sort it alphabetically and check if they are still unequal. That means it is not possible to make it equal after swaping.\n\nReturn true if it is possible to make both strings equal by performing at most one string swap on exactly one of the strings. Otherwise, return false.\n\nAs in the question it is already mention that the both strings equal by performing **at most one** string swap on exactly one of the strings\n\nif exactly we get 2 after counting the unequal character of the the two strings, then the strings are equal.\n\n# Code\n```\nclass Solution:\n    def areAlmostEqual(self, s1: str, s2: str) -> bool:\n        if s1 == s2:\n            return True\n        elif sorted(s1) != sorted(s2):\n            return False\n        \n        count =0\n        for i in range(len(s1)):\n            if s1[i] != s2[i]:\n                count += 1\n        \n        if count !=2:\n            return False\n        return True\n```\n<img src="https://assets.leetcode.com/users/images/26e0d290-2307-44c7-9aac-3bb5fb65ad4d_1684683655.5701103.png">\n\nscreenshot for beats\n![image.png](https://assets.leetcode.com/users/images/2d67b245-f204-4764-b012-9219989cde60_1677981776.707594.png)\n
['Python3']