C++ Sweet Solution
Just check the indexes and relative order of L and R and count of R\'s and L\'s\n\nclass Solution {\npublic:\n    bool canChange(string start, string target) {\
Just check the indexes and relative order of L and R and count of R\'s and L\'s\n```\nclass Solution {\npublic:\n    bool canChange(string start, string target) {\n        int i=0,j=0,loi=0,n=start.length();\n        int SL=0,SR=0,TL=0,TR=0;\n        for(int i=0;i<n;i++){\n            if(start[i]==\'R\')SR++;\n            else if(start[i]==\'L\')SL++;\n            if(target[i]==\'L\')TL++;\n            else if(target[i]==\'R\')TR++;\n        }\n        if(SL!= TL || SR!=TR)return false;\n        while(i<n && j<n){\n            while(i<n && start[i++]==\'_\');\n            while(j<n && target[j++]==\'_\');\n            i--;j--;\n            if(start[i]!=target[j])return false;\n            if(start[i]==\'L\'){\n                if(i<j)return false;\n            }\n            if(start[i]==\'R\'){\n                if(i>j)return false;\n            }\n            i++;j++;\n        }\n        return true;\n    }\n};\n```
['C']