백준 / 1987번 / 알파벳 / python 파이썬
·
코딩테스트/백준 (python)
문제 : https://www.acmicpc.net/problem/1987 나의 풀이 (시간 초과)import sysinput = sys.stdin.readlineR, C = map(int, input().split())board = [[_ for _ in range(C)] for _ in range(R)]for i in range(R): alp = input() for j in range(C): board[i][j] = alp[j]dx = [-1, 1, 0, 0]dy = [0, 0, -1, 1]def DFS(x, y, visited, count): global max_count max_count = max(max_count, count) for i in ra..