[프로그래머스] <삼각 달팽이> 파이썬
programmers.co.kr/learn/courses/30/lessons/68645 코딩테스트 연습 - 삼각 달팽이 5 [1,2,12,3,13,11,4,14,15,10,5,6,7,8,9] 6 [1,2,15,3,16,14,4,17,21,13,5,18,19,20,12,6,7,8,9,10,11] programmers.co.kr 그냥 배열에 때려 넣기 def solution(n): arr = [[0] * i for i in range(1,n+1)] dx = [1,0,-1] dy = [0,1,-1] direction = 2 value = 0 x, y = -1, 0 while n : direction = (direction + 1) % 3 for i in range(0, n) : x, y = x+dx[direc..