
상하좌우 [ y, x 분리 ]n = int(input())a = list(input().split())posX, posY = 1, 1move = ['L', 'R', 'U', 'D']dx = [-1, 1, 0, 0]dy = [0, 0, -1, 1]for i in a: k = move.index(i) if posX + dx[k] 왕실의 나이트 [ y, x 형식 ]current_pos = input()row = int(current_pos[1])col = int(ord(current_pos[0]) - int(ord('a'))) + 1count = 0steps = [(-2, -1), (-2, 1), (-1, 2), (1, 2), (2, 1), (2, -1), (1, -2),(-1, -2)]for..