1) 백조 만날수 있는지 체크
만날수 있으면 ) 날짜 출력
not ->
if . 이면
1) 상하좌우 X존재하는지 확인 -> .으로 바꾸기
if x 이면
넘어가기
) 날짜 1올리기
R , C = map(int, sys.stdin.readline())
l = []
for i in range(R) :
a = list(sys.stdin.readline())
l.append(a)
def check(l):
def changeX(e):
while(1) :
c = check(l)
if c == 1:
print(date)
break
else:
for i in l:
for e in i:
if e == "." or e == "L":
l = changeX(e)
else :
continue
date += 1
print(date)