Skip to content

Commit 98db791

Browse files
author
A Safari
authored
Create Non-crossing-lines-to-connect-points-in-a-circle
1 parent 6a95bf9 commit 98db791

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
def count(n):
2+
if (n & 1):
3+
return 0
4+
val = n // 2
5+
dy_lst = [1 for i in range(val + 1)]
6+
for i in range(2, val + 1):
7+
dy_lst[i] = 0
8+
for j in range(i):
9+
dy_lst[i] += (dy_lst[j] * dy_lst[i - j - 1])
10+
return dy_lst[val]

0 commit comments

Comments
 (0)