There was an error while loading. Please reload this page.
2 parents 9763da6 + 7533df4 commit 9ddb1e2Copy full SHA for 9ddb1e2
1 file changed
leetcode3/최민지/3803.py
@@ -0,0 +1,11 @@
1
+class Solution:
2
+ def residuePrefixes(self, s: str) -> int:
3
+ result = 0
4
+
5
+ for i in range(1, len(s) + 1):
6
+ prefix = s[:i]
7
8
+ if len(set(prefix)) == len(prefix) % 3:
9
+ result += 1
10
11
+ return result
0 commit comments