In some other world, today is the day before Christmas Eve.
Mr. Takaha is buying N items at a department store. The regular price of the i-th item (1 \leq i \leq N) is p_i yen (the currency of Japan).
He has a discount coupon, and can buy one item with the highest price for half the regular price. The remaining N-1 items cost their regular prices. What is the total amount he will pay?

-----Constraints-----
 - 2 \leq N \leq 10
 - 100 \leq p_i \leq 10000
 - p_i is an even number.

-----Input-----
Input is given from Standard Input in the following format:
N
p_1
p_2
:
p_N

-----Output-----
Print the total amount Mr. Takaha will pay.

-----Sample Input-----
3
4980
7980
6980

-----Sample Output-----
15950

The 7980-yen item gets the discount and the total is 4980 + 7980 / 2 + 6980 = 15950 yen.
Note that outputs such as 15950.0 will be judged as Wrong Answer.

Difficulty: introductory

Starter code:

Solutions:
def main():
    p = []
    sum_cost = 0
    n = int(input())
    for i in range(n):
        p.append(int(input()))
    max_p = max(p)
    p[p.index(max_p)] = max_p / 2
    print((int(sum(p))))


def __starting_point():
    main()

__starting_point()

n = int(input())
p = [int(input()) for i in range(n)]
p = sorted(p, reverse=True)
result = p[0] // 2
for i in range(n-1):
    result += p[i+1]

print(result)

# 数値の取得
pnum = int(input())
plist = list()
for pcnt in range(0,pnum,1):
    plist.append(int(input()))

# 合計金額を出力
half = max(plist) // 2
psum = sum(plist) - half
print(psum)

N = int(input())
P = []
for i in range(N):
    P.append(int(input()))

total_price = (max(P) // 2) + (sum(P) - max(P))

print(total_price)

# B - Christmas Eve Eve

#  N
N = int(input())
my_list = []

for i in range(0, N):
    my_list.append(int(input()))

my_list = sorted(my_list, reverse=True)
my_list[0] = int(my_list[0] / 2)
answer = sum(my_list)

print(answer)


count_gift = int(input())
price_list = []
total_payment = 0

for _ in range(count_gift):
    price_list.append(int(input()))

price_list.sort(reverse=True)
total_payment = price_list.pop(0) // 2

for i in price_list:
    total_payment += i

print(total_payment)


N = int(input())
p = [int(input()) for _ in range(N)]

print((sum(p) - max(p) // 2))


N = int(input())
P = sorted([int(input()) for x in range(N)])

m = P[N-1]
P = P[:N-1]
print(sum(P) + m // 2)

# 115b

def atc_115b(N: int, Pi_input: int) -> int:
    Pi_input = sorted(Pi_input)
    max_price = Pi_input.pop()
    return int(sum(Pi_input) + max_price / 2)

N_input_value = int(input())
Pi_input_value = []
for i in range(0, N_input_value):
    Pi_input_value.append(int(input()))
print((atc_115b(N_input_value, Pi_input_value)))


N=int(input())
P=sorted([int(input()) for _ in range(N)])

print((sum(P)-P[-1]+P[-1]//2))


a = int(input())
l = []
for i in range(a):
  l.append(int(input()))
b = max(l)
print(sum(l)-b//2)

n=int(input())
p=[int(input()) for i in range(n)]
total=0
for i in range(n):
  total+=p[i]
total-=max(p)*0.5
print(int(total))

N = int(input())
a = []

for _ in range(0, N):
    a.append(int(input()))

a1 = sorted(a, reverse=True)
price = a1[0] // 2 + sum(a1) - a1[0]

print(price)

# とある世界では、今日はクリスマスイブの前日です。高羽氏は、デパートでN個の品物を買おうとしています。i個目の品物(1≤i≤N)の定価はpi円です。
# 彼は割引券を持っており、N個のうち最も定価が高い品物1個を定価の半額で買うことができます。残りのN−1個の品物に対しては定価を支払います。
# 支払金額は合計でいくらになるでしょうか？

N = int(input())
list = [int(input()) for i in range(N)]

expensive = max(list)
discount = expensive // 2
total = sum(list) - expensive + discount

print(total)

n = int(input())
p = list(int(input()) for _ in range(n))
p.append(p.pop(p.index(max(p))) // 2)
print(sum(p))


n=int(input())
p=[int(input()) for i in range(n)]

k=0

m=max(p)
l=int(m/2)

for i in p:
    k=k+i

print((k-l))






n = int(input())
ans = 0
ml = []
for i in range(n):
  a = int(input())
  ml.append(a)
x = max(ml) / 2

ans = sum(ml) - x
print((int(ans)))



n = int(input())
ans = 0
lis = [int(input()) for _ in range(n)]
ma = lis.pop(lis.index(max(lis)))
print(sum(lis) + int(ma*0.5))

N = int(input())
p = [int(input()) for _ in range(N)]
 
p_sum = 0
p_max = 0
for i in range(N):
  p_sum += p[i]
  p_max = max(p_max, p[i])
  
print(p_sum - p_max // 2)

n = int(input())
p = [0]*n
for i in range(n):
  p[i]=int(input())
answer = sum(p)
answer -= max(p)//2
print(answer)

N = int(input())
a = []
for _ in range(0, N):
    a.append(int(input()))

price=max(a)//2+sum(a)-max(a)

print(price)



n=int(input())
p=[int(input()) for i in range(n)]
print((sum(p)-max(p)//2))
    





def mapt(fn, *args):
    return tuple(map(fn, *args))


def Input():
    return mapt(int, input().split(" "))


def main():
    n = int(input())
    data = sorted(int(input()) for _ in range(n))
    x, y = data[:-1], data[-1]
    print((sum(x)+y//2))


main()


N = int(input())
p = []
for _ in range(0, N):
    p.append(int(input()))

print(int(sum(p) - max(p) / 2))

N=int(input())
l = [input() for _ in range(N)]

def ans115(N:int,l:list):
    l=sorted(map(int,l))
    count=0
    for i in range(0,N-1):
        count+=l[i]
    return(int(count+l[N-1]*0.5))

print(ans115(N,l))

n = int(input())
p = [int(input()) for _ in range(n)]

print(sum(p) - max(p) // 2)

N = int(input())
p = []
for i in range(N):
  p.append(int(input()))
p.sort()
ans = sum(p) - p[-1]//2
print(ans)

import math
import collections
from itertools import product

ii = lambda : int(input())
mi = lambda : map(int,input().split())
li = lambda : list(map(int,input().split()))

n = ii()
p = [ii() for i in range(n)]
p.sort()
p[-1] //= 2
print(sum(p))

N = int(input())
p = []
for i in range(N):
    p.append(int(input()))
a = max(p)
p.remove(a)
s = 0
for i in p:
    s += i
print((s + a//2))



n = int(input())
# n個の入力値をリストに追加
p = []
for _ in range(0,n):
    p.append(int(input()))
# リストの合計からリスト中の最大値の1/2を引く
print(int(sum(p) - max(p) / 2))

total_item = int(input())
item_cost = []
for i in range(total_item):
    item_cost.append(int(input()))
print(sum(item_cost) - max(item_cost) // 2)

N = int(input())
present = []
for i in range(N):
     price = int(input())
     present.append(price)

present.sort(reverse=True)
# print(present)
max_price = present.pop(0)

ans = max_price // 2 + sum(present)
print(ans)

N=int(input())
p=[int(input()) for i in range(N)]

ans = 0
for i in range(N):
	ans += p[i]

ans -=max(p)//2

print(ans)

N = int(input())
data = list(range(N))
m = 0
while m < N:
    data[m] = int(input())
    m += 1

kei = 0
max = 0
for i in range(len(data)):
    kei += data[i]
    if max < data[i]:
        max = data[i]

kei = kei - max / 2
print((int(kei)))


n = int(input())
prices = []
for i in range(0, n):
    prices.append(int(input()))

payment = int(max(prices) / 2 + sum(prices) - max(prices))
print(payment)

n = int(input())
p =[int(input()) for i in range(n)]
p.sort()
p[len(p) - 1] = p[len(p) - 1] //2
print(sum(p))

N = int(input())
p = []

for i in range(N):
    p.append(int(input()))

max_p = max(p)
ans = int(max_p/2) + sum(p) - max_p

print(ans)


N = int(input())
lst = []
for i in range(N):
    P = int(input())
    lst.append(P)
ans = sum(lst) - int(max(lst) / 2)
print(ans)

N = int(input())
P = [int(input()) for _ in range(N)]

sortP = sorted(P)
ans = sum(sortP[:-1]) + sortP[-1]/2
print((int(ans)))


N = int(input())

prices = []

for _ in range(N):
    prices.append(int(input()))

prices.append(max(prices) // 2)
prices.remove(max(prices))

print(sum(prices))

N = int(input())
p = list(int(input()) for _ in range(N))

print(sum(p) - max(p) // 2)

N = int(input())
p = [int(input()) for i in range(N)]

a = sum(p)
print(int(a - max(p) / 2))

N = int(input())
P = sorted(list(int(input()) for _ in range(N)),reverse=True)
P[0] = int(P[0]*.5)
print((sum(P)))


def christmas_eve_eve(price_list: list):
    price_list.sort()
    price_list[-1] /= 2
    return int(sum(price_list))


def __starting_point():
    prices = []
    n = int(input())
    for i in range(n):
        prices.append(int(input()))

    print((christmas_eve_eve(prices)))

__starting_point()

n = int(input())
# n個の入力値をリストに追加
p = []
for _ in range(0,n):
    p.append(int(input()))
# リストの合計からリスト中の最大値の1/2を引く
print(int(sum(p) - max(p) / 2))

n = int(input())
p = [int(input()) for i in range(n)]
print(max(p)//2 + sum(p)-max(p))

N = int(input())
sum = 0
price_list = []

for i in range(N):
    price_list.append(int(input()))

ex_product = max(price_list)
dis_ex_product = ex_product // 2

for i in price_list:
    sum += i

answer = sum - dis_ex_product

print(answer)

N = int(input())
p = [int(input()) for _ in range(N)]

print(sum(p) - max(p) // 2)

N = int(input())
 
p_sum = 0
p_max = 0
for i in range(N):
  p = int(input())
  p_sum += p
  p_max = max(p_max, p)
  
print(p_sum - p_max // 2)

# import numpy as np
# import math

# from scipy.special import perm : perm(n, r, exact=True)
# from scipy.special import comb : comb(n, r, exact=True)

# import itertools
# for v in itertools.combinations(L, n):M.append(list(v))

# from numba import njit
# @njit('f8(i8,i8,i8,i8,f8[:,:,:])', cache=True)


""" Definitions  """

def lcm(a, b):
    return a*b//math.gcd(a, b)

MOD = 10**9+7

# ============================================================

N = int(input())

ans = 0
P = []
for i in range(N):
    p = int(input())
    P.append(p)
    ans += p
ans -= max(P)//2
print(ans)


n = int(input())
L = sorted(list(int(input()) for _ in range(n)))
ans = 0
for i in range(n):
  if i == (n-1):
    ans += L[i]//2
  else:
    ans += L[i]
print(ans)

N = int(input())
p = list(int(input()) for i in range(N))

# 合計支払金額を (整数として) 出力せよ。
# 注意：1版高い商品は半額

print(sum(p) - max(p) // 2)

n = int(input())
max_price = 0
prices = []

for _i in range(n):
  price = int(input())
  prices.append(price)
  if max_price < price:
    max_price = price

print(sum(prices) - max_price//2)

p = [int(input()) for i in range(int(input()))]
print(sum(p) - max(p) // 2)

import re
import sys
import math
import itertools
import bisect
from copy import copy
from collections import deque,Counter
from decimal import Decimal
import functools
def v(): return input()
def k(): return int(input())
def S(): return input().split()
def I(): return list(map(int,input().split()))
def X(): return list(input())
def L(): return list(input().split())
def l(): return list(map(int,input().split()))
def lcm(a,b): return a*b//math.gcd(a,b)
sys.setrecursionlimit(10 ** 6)
mod = 10**9+7
cnt = 0
ans = 0
inf = float("inf")
al = "abcdefghijklmnopqrstuvwxyz"
AL = al.upper()

n,*a=list(map(int,open(0)));print((sum(a)-max(a)//2))


N = int(input())
list = [int(input()) for i in range(N)]

print(sum(list) - max(list) // 2)

N = int(input())
p = [int(input()) for i in range(N)]

answer = sum(p)

print(int(answer - max(p) * 0.5))

n = int(input())
li = []
for i in range(n):
    li.append(int(input()))

li.sort()
li[-1] = li[-1]//2

print(sum(li))

N = int(input())
m, *P = sorted([int(input()) for x in range(N)], reverse=True)

"""
m = P[N-1]
P = P[:N-1]
"""

print(sum(P) + m // 2)

import math
N = int(input())
p = []

for i in range(N):
    p.append(int(input()))

total_price = max(p) / 2 + sum(p) - max(p)

print(math.floor(total_price))

N = int(input())
p = []

for i in range(N):
    p.append(int(input()))
print(sum(p)-max(p)//2)

N = int(input())
lists = []
for _ in range(1, N + 1):
    lists.append(int(input()))

sums = 0

for i in range(0, N):
    sums += lists[i]

sums -= int(max(lists) / 2)

print(sums)

N = int(input())
p = [int(input()) for i in range(N)]

descending_p = sorted(p, reverse=True)
# print(descending_p)

# 一番の高額は半額
discount_price = descending_p[0] // 2
# print(discount_price)

# 他は定価で買う
list_price = sum(descending_p[1:])
# print(list_price)

total_price = discount_price + list_price
print(total_price)


n = int(input())
list_p = sorted([int(input()) for n in range(0, n)])
print(sum(list_p[:n - 1]) + list_p[n - 1] // 2)

n = int(input())
l = [int(input()) for i in range(n)]

ans = sum(l) - max(l) + max(l)//2
print(ans)

n = int(input())
p = [int(input()) for _ in range(n)]

def answer(n: int, p: int) -> int:
    a = sum(p) - max(p) // 2
    return a

print(answer(n, p))

N = int(input())
P = list(int(input()) for i in range(N))
expensive = max(P)
other = sum(P) - expensive

print(expensive // 2 + other)

#!/usr/bin/env python3

def main():
    p = [int(input()) for i in range(int(input()))]
    print((sum(p) - max(p) // 2))


def __starting_point():
    main()

__starting_point()

  
# 115b

def atc_115b(N: int, Pi_input: int) -> int:
    Pi_input = sorted(Pi_input)
    max_price = Pi_input.pop()
    return int(sum(Pi_input) + max_price / 2)

N_input_value = int(input())
Pi_input_value = []
for i in range(0, N_input_value):
    Pi_input_value.append(int(input()))
print(atc_115b(N_input_value, Pi_input_value))

N = int(input())
S_list = [int(input()) for i in range(N)]
p_max = max(S_list)
p_sum = sum(S_list)
result = int(p_max / 2) + p_sum - p_max
print(result)

def readinput():
    n=int(input())
    p=[]
    for _ in range(n):
        p.append(int(input()))
    return n,p

def main(n,p):
    p.sort(reverse=True)
    #print(p)
    p[0]=p[0]//2
    return sum(p)

def __starting_point():
    n,p=readinput()
    ans=main(n,p)
    print(ans)

__starting_point()

import math
N = int(input())
p = []
for i in range(N):
    p.append(int(input()))

result = max(p)/2 + sum(p) - max(p)

print(math.floor(result))

a=int(input())
b=[int(input()) for i in range(a)]
b.sort()
b[len(b)-1]=int(b[len(b)-1]/2)
print(sum(b))

N = int (input ())
l = []
a = 0
for i in range (N):
  x = int (input ())
  a += x
  l.append (x)
n = max (l)/2
print (round (a-n))

n=int(input())
p=[int(input()) for i in range(n)]

p.sort()

print(int(sum(p)-p[-1]*(1/2)))

n=int(input())
l=[]
for i in range(n):
    l.append(int(input()))
i=l.index(max(l))
l[i]=l[i]//2
print((sum(l)))


n = int(input())
l = [int(input()) for _ in range(n)]

print((sum(l) - (max(l) // 2)))


import sys


def input(): return sys.stdin.readline().strip()
def I(): return int(input())
def LI(): return list(map(int, input().split()))
def IR(n): return [I() for i in range(n)]
def LIR(n): return [LI() for i in range(n)]
def SR(n): return [S() for i in range(n)]
def S(): return input()
def LS(): return input().split()


INF = float('inf')


n = I()
p = IR(n)
p.sort()
ans = sum(p[:-1]) + p[-1]//2
print(ans)


N=int(input())
p=[int(input()) for _ in range(N)]
p.sort()
print((sum(p[0:N-1])+p[-1]//2))


#ABC115B
n = int(input())
p = [int(input()) for i in range(n)]
print(sum(p)-max(p)//2)

n = int(input())
p=list(int(input()) for i in range(n))


print(sum(p)-max(p)//2)

N = int(input())
p = [int(input()) for i in range(N)]
ans = 0
for i in p:
  ans += i
ans -= int(max(p)/2)
print(ans)

# ABC115
# B Christmas Eve Eve
N = int(input())
P = []
for n in range(N):
    P.append(int(input()))
P = sorted(P,reverse=True)
print((sum(P) - P[0]//2))


n = int(input())
p = []
for i in range(n):
    p.append(int(input()))

print(sum(p) - max(p) // 2)

N = int(input())
p = [int(input()) for i in range(N)]
p = sorted(p)
harai=0

harai = sum(p)-(p[-1]//2)

print(harai)

n = int(input())
al = [int(input()) for _ in range(n)]

mm = max(al)

print(sum(al)-mm//2)

def answer(n: int, p: []) -> int:
    p.append(p.pop(p.index(max(p))) // 2)
    return sum(p)


def main():
    n = int(input())
    p = list(int(input()) for _ in range(n))
    print(answer(n, p))


def __starting_point():
    main()
__starting_point()

n = int(input())
p = [int(input()) for i in range(n)]
p.sort()
p[n-1] /= 2;
print((int(sum(p))))


N = int(input())
p = []
for i in range(N):
    p.append(int(input()))

Expensive = max(p)
p.remove(Expensive)
print(Expensive // 2 + sum(p))

n=int(input())

p=[int(input()) for i in range(n)]

ans=max(p)//2+sum(p)-max(p)

print(ans)

# import math
# import statistics
# import itertools
a=int(input())
#b,c=int(input()),int(input())
# c=[]
# for i in a:
#     c.append(int(i))
# e1,e2,e3,e4 = map(int,input().split())
#f = list(map(int,input().split()))
g = [int(input()) for _ in range(a)]

ma = max(g)
del g[g.index(ma)]
print(int(sum(g)+ma/2))

n = int(input())
list01 = []
for i in range(n):
    list01.append(int(input()))
print(sum(list01) - max(list01) // 2)

N = int(input())
p = []
for i in range(N):
  p.append(int(input()))

p.sort()
cost = 0
for i in range(N-1):
  cost += p[i]
print(cost + p[N-1]//2)

n=int(input())
P=[int(input()) for i in range(n)]
print(sum(P)-max(P)//2)

N = int(input())

p = []

for i in range(N):
    p.append(int(input()))
    
p.sort()
p.reverse()

p[0] //= 2

print(sum(p))

n = int(input())
p = [int(input()) for i in range(n)]

# 一番高いものは半額
print(sum(p)-max(p)//2)

n = int(input())
p = []
for i in range(n):
  p.append(int(input()))
print(sum(p)-max(p)//2)

N = int(input())
P = [int(input()) for _ in range(N)]

print(sum(P)-max(P)//2)

N = int(input())
P = []
for i in range(N):
    P.append(int(input()))

print((sum(P) - max(P) // 2))