解题思路
“A”的数量小于2,"LLL"在s中不存在即可
代码
class Solution:
def checkRecord(self, s: str) -> bool:
return s.count("A") < 2 and "LLL" not in s
Leetcode_Python 551 学生出勤记录 I
阅读 72
2023-04-07
“A”的数量小于2,"LLL"在s中不存在即可
class Solution:
def checkRecord(self, s: str) -> bool:
return s.count("A") < 2 and "LLL" not in s
相关推荐
精彩评论(0)