n=int(input())
vilige = list(map(int,input().split()))
vilige.sort(reverse=True)
result = 0
for i in range(n-1):
result += vilige.pop()
print(result)
'문제풀이 > 백준(Boj) 문제풀이' 카테고리의 다른 글
[백준][분할 정복] 1629. 곱셈(파이썬/Python) (0) | 2021.10.05 |
---|---|
[백준][그리디 알고리즘] 20044. Project Teams(파이썬/Python) (0) | 2021.10.04 |
[백준][동적 계획법1] 11726. 2×n 타일링(파이썬/Python) (0) | 2021.10.04 |
[백준][분할 정복] 1992. 쿼드트리 (파이썬/Python) (0) | 2021.10.04 |
[백준][그리디 알고리즘] 1744. 수 묶기 (파이썬/Python) (0) | 2021.10.03 |