카카오 2022 파괴 되지 않는 건물
파이썬 (정확도만 통과) #skill = [type, r1, c1, r2, c2, degree] from multiprocessing.connection import answer_challenge def solution(board, skill): answer = 0 for arr in skill: if arr[0] == 1 : #공격 attack(board, arr) elif arr[0] == 2: #회복 heal(board, arr) for arr in board: for i in arr: if i > 0 : answer += 1 return answer def attack(board, arr): x1, y1, x2, y2 , degree = arr[1:6] for i in range(x1, x2+1)..