LeetCode 2839: Check Strings Equal (Easy Explanation + Code)
Problem Summary You are given two strings s1 and s2, both of length 4. You can perform the following operation any number of times: Return true if you can make s1 equal to s2, otherwise false. 🔍 Key Observation The allowed swaps create two independent groups of indices: Within each group, characters can be freely … Read more