Posted on August 17, 2021August 17, 2021 Description Submission class Solution { public: bool checkRecord(string s) { int aCount = 0, lCount = 0; for(char ch: s) { if(ch == 'L') ++lCount; else lCount = 0; if(lCount >= 3) return false; if(ch == 'A') ++aCount; } return aCount < 2; } }; By Bill0412 Easy LeetCode