1433. Check If a String Can Break Another String
Description
**Input:** s1 = "abc", s2 = "xya"
**Output:** true
**Explanation:** "ayx" is a permutation of s2="xya" which can break to string "abc" which is a permutation of s1="abc".**Input:** s1 = "abe", s2 = "acd"
**Output:** false
**Explanation:** All permutations for s1="abe" are: "abe", "aeb", "bae", "bea", "eab" and "eba" and all permutation for s2="acd" are: "acd", "adc", "cad", "cda", "dac" and "dca". However, there is not any permutation from s1 which can break some permutation from s2 and vice-versa.**Input:** s1 = "leetcodee", s2 = "interview"
**Output:** trueac
Previous1432. Max Difference You Can Get From Changing an IntegerNext1434. Number of Ways to Wear Different Hats to Each Other
Last updated