๋ฌธ์
https://school.programmers.co.kr/learn/courses/30/lessons/12914
ํ์ด
def solution(n):
if n<3:
return n
d=[0]*(n+1)
d[1]=1
d[2]=2
for i in range(3,n+1):
d[i]=d[i-1]+d[i-2]
return d[n]%1234567
๊ฐ๋จํ DP ๋ฌธ์ ์ด๋ค.