Skip to content

Commit b41b9d0

Browse files
Merge pull request #1815 from CodingTestStudy2/김민제
[김민제] Day14
2 parents fed4acb + 74a6f43 commit b41b9d0

1 file changed

Lines changed: 12 additions & 0 deletions

File tree

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
from collections import Counter
2+
from math import gcd
3+
4+
def solution(deck):
5+
counts = Counter(deck).values()
6+
x = 0
7+
for count in counts:
8+
x = gcd(x,count)
9+
return x>1
10+
11+
arr = [1,2,3,4,4,3,2,1]
12+
print(solution(arr))

0 commit comments

Comments
 (0)