Heeto
article thumbnail
[ 백준 ][ 골드3 ] 163236번 - 아기 상어 ( 파이썬 Python )

링크 : https://www.acmicpc.net/problem/16236 16236번: 아기 상어 N×N 크기의 공간에 물고기 M마리와 아기 상어 1마리가 있다. 공간은 1×1 크기의 정사각형 칸으로 나누어져 있다. 한 칸에는 물고기가 최대 1마리 존재한다. 아기 상어와 물고기는 모두 크기를 가 www.acmicpc.net 코드 from collections import deque n = int(input()) sx,sy = -1,-1 graph = [] eat_cnt, fish_cnt, time, size = 0, 0, 0, 2 dx,dy = [-1,0,0,1],[0,-1,1,0] for i in range(n): l = list(map(int,input().split())) for j in ran..