[BaekJoon] 2480번: 주사위 세개 (Python)
- Reference
- 악명 높은 수학 문제 치고는 너무 재밌었다!
Solution
array = list(map(int, input().split()))
count_same = 0
index_dict = {}
for i in range(len(array)):
if array.count(array[i]) > count_same:
count_same = array.count(array[i])
index_dict[count_same] = array[i]
if count_same == 3:
print(10000 + index_dict[count_same] * 1000)
elif count_same == 2:
print(1000 + index_dict[count_same] * 100)
else:
print(max(array) * 100)
Leave a comment