-Code
n = int(input())
total = [input() for _ in range(2)]
dot_cnt, flag, res = 0, False, ""
for el in total[1][3:]:
if el == '.':
dot_cnt += 1
elif el == '\\':
if dot_cnt == 2:
flag = True
elif dot_cnt == 3:
res += "w" if flag else "v"
flag = False
dot_cnt = 0
res += "w" if flag else "v"
print(res)
'Beakjoon&프로그래머스 > 파이썬' 카테고리의 다른 글
[백준/파이썬] 29342번 Война клонов (0) | 2025.04.29 |
---|---|
[백준/파이썬] 29575번 Игровой автомат (0) | 2025.04.28 |
[백준/파이썬] 31496번 자작나무가 없소~ (0) | 2025.04.26 |
[백준/파이썬] 25177번 서강의 역사를 찾아서 (0) | 2025.04.25 |
[백준/파이썬] 31844번 창고지기 (0) | 2025.04.24 |