-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathP13699.py
11 lines (10 loc) · 1.03 KB
/
P13699.py
1
2
3
4
5
6
7
8
9
10
11
# https://www.acmicpc.net/problem/13699
# 2020-07-08 / 13699. 점화식 / Silver IV
# t = [1, 1, 2, 5, 14, 42, 132, 429, 1430, 4862, 16796, 58786, 208012, 742900, 2674440, 9694845, 35357670, 129644790, 477638700, 1767263190, 6564120420, 24466267020, 91482563640, 343059613650, 1289904147324, 4861946401452, 18367353072152, 69533550916004, 263747951750360, 1002242216651368, 3814986502092304, 14544636039226909, 55534064877048198, 212336130412243110, 812944042149730764, 3116285494907301262]
# print((1, 1, 2, 5, 14, 42, 132, 429, 1430, 4862, 16796, 58786, 208012, 742900, 2674440, 9694845, 35357670, 129644790, 477638700, 1767263190, 6564120420, 24466267020, 91482563640, 343059613650, 1289904147324, 4861946401452, 18367353072152, 69533550916004, 263747951750360, 1002242216651368, 3814986502092304, 14544636039226909, 55534064877048198, 212336130412243110, 812944042149730764, 3116285494907301262)[int(input())])
t = [1]
for i in range(1, 35 + 1):
t.append(0)
for j in range(0, i):
t[i] += t[j] * t[i - j - 1]
print(t[int(input())])