Skip to content

Commit a6d9211

Browse files
committed
[PGS] 피보나치 수 / Level 2 / 11분 (성공)
1 parent a6dce55 commit a6d9211

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
def solution(n):
2+
a = 0
3+
b = 1
4+
temp = 0
5+
# 0 1 1 2 3 5 8 13 21 34 55
6+
for i in range(n):
7+
temp = b
8+
b = a + b
9+
a = temp
10+
11+
return a % 1234567

0 commit comments

Comments
 (0)