-Code
korea = "KOREA"
s = input()
res = ""
for w in s:
if korea[len(res) % 5] == w:
res += w
print(len(res))
'Beakjoon&프로그래머스 > 파이썬' 카테고리의 다른 글
[백준/파이썬] 30315번 King's Keep (1) | 2024.06.06 |
---|---|
[백준/파이썬] 6139번 Speed Reading (0) | 2024.06.05 |
[백준/파이썬] 31458번 !!초콜릿 중독 주의!! (0) | 2024.06.03 |
[백준/파이썬] 31907번 GIST 찍기 (0) | 2024.06.02 |
[백준/파이썬] 31048번 Last Factorial Digit (0) | 2024.06.01 |