Problem:
 Score : 200 points    Problem Statement 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 1 3
4980
7980
6980      Sample Output 1 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.       Sample Input 2 4
4320
4320
4320
4320      Sample Output 2 15120  Only one of the four items gets the discount and the total is 4320 / 2 + 4320 + 4320 + 4320 = 15120 yen.

Solution (Python):
n=int(input())
p=[]
price=0
for i in range(n):
    q=int(input())
    p.append(q)
p=sorted(p)
for i in range(n-1):
    price+=p[i]
price+=p[-1]/2.
print(int(price))

Solution (Python):
n = int(input())
p = []
for _ in range(n):
    p.append(int(input()))

p.sort()
p.reverse()

p[0] /= 2

print(int(sum(p)))

Solution (Python):
n = int(input())
lis = []
for i in range(n):
    lis.append(int(input()))

maxLis = max(lis)
sumLis = sum(lis)
answer = sumLis - maxLis // 2
print(answer)

Solution (Python):
N = int(input())
P = [int(input()) for i in range(N)]
print(sum(P)-max(P)//2)

Solution (Python):
n = int(input())
li_p = list()
for i in range(n):
    li_p.append(int(input()))

print(sum(p if idx != 0 else int(p/2) for idx, p in enumerate(sorted(li_p, reverse=True))))

Solution (Python):
lis=[int(input())for i in range(int(input()))];print(sum(lis)-max(lis)//2)

Solution (Python):
n = int(input())
li = []
for _ in range(n):
    li.append(int(input()))
li.sort()
total = 0
for i in range(len(li) - 1):
    total += li[i]
total = total + li[-1] // 2
print(total)

Solution (Python):
lis=[int(input())for i in range(int(input()))];print(int(max(lis)/2+sum(lis)-max(lis)))

Solution (Python):
a=int(input());lis=[int(input()) for i in range(a)]
print(int(max(lis)/2+sum(lis)-max(lis)))

Solution (Python):
X = int(input())
s = [int(input()) for i in range(X)]
sum = 0
s.sort()
s.reverse()
for i in range(len(s)):
    if i == 0:
        sum += s[i]/2
    else:
        sum += s[i]


print(int(sum))

Solution (Python):
N=int(input())
price=[int(input()) for i in range(N)]
price.sort(reverse=True)
price[0]=price[0]//2
a=sum(price)
print(a)

Solution (Python):

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

Price.sort()
Price.reverse()

Price[0] //= 2
s = sum(Price)
print(s)

Solution (Python):
a = int(input())
result = 0
l = sorted([int(input()) for i in range(a)],reverse=True)
m = max(l)/2
l.remove(max(l))
result = result + m + sum(l)
print(int(result))

Solution (Python):
n = int(input())
s = [int(input()) for i in range(n)]
print(sum(s)-int(max(s)/2))

Solution (Python):
l=[int(input()) for _ in range(int(input()))]
print(sum(l)-int(max(l)/2))

Solution (Python):
n = int(input())
list = [int(input()) for i in range(n)]
sum = 0
for i in range(n):
  sum = sum + list[i]

m = max(list)
sum = sum - m

print(int(m/2) + sum)

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

Solution (Python):

"""
Created on Wed Jan  2 09:53:30 2019

@author: Yamazaki Kenichi
"""

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

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

print(ans)

Solution (Python):
n = int(input())
l = [int(input()) for i in range(n)]
sum = 0
for i in range(n):
  sum += l[i]
r = max(l) / 2
sum -= r
print(int(sum))

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

Solution (Python):
n=int(input())
i=1
sum=0
max=0
while i <= n:
    ni=int(input())
    sum=sum+ni
    if ni > max:
        max=ni
    i +=1
goke=sum-max/2
print(int(goke))

Solution (Python):
n = int(input())
plist = []
for i in range(n):
  plist.append(int(input()))
maxp = max(plist)
ans = sum(plist) - maxp * 0.5
print(int(ans))

Solution (Python):
n = int(input())
ps = [int(input()) for i in range(n)]
print(sum(ps) - max(ps)//2)

Solution (Python):

items = int(input())

price_array = []


for _ in range(items):
    price = int(input())
    price_array.append(price)

price_sum = sum(price_array)
half_price = max(price_array)//2

result = price_sum - half_price
print(result)

Solution (Python):
n = int(input())
p = []
for _ in range(n):
  p.append(int(input()))
p.sort(reverse=True)
p[0] = p[0] // 2
print(sum(p))

Solution (Python):
n=int(input())
p=[int(input()) for i in range(n)]
p.sort(reverse=True)
s=p[0]//2
for j in range(1,n):
    s+=p[j]
print(s)

Solution (Python):
N = int(input())
p = [0]*N
for i in range(N):
    p[i] = int(input())

ans = sum(p)-0.5*max(p)
print(int(ans))

Solution (Python):
N = int(input())
P = []
for _ in range(N):
	P.append(int(input()))
P.sort(reverse=True)
print(P.pop(0)//2 + sum(P))

Solution (Python):
N=int(input())
p=[0]*N
for i in range(N):
    p[i]=int(input())
p.sort()
p[N-1]=p[N-1]//2
ans=0
for i in range(N):
    ans+=p[i]
print(ans)

Solution (Python):
def piyo():
    n = int(input()) 
    p = [int(input()) for i in range(n)]
    p[p.index(max(p))]=p[p.index(max(p))]//2
    print(sum(p))

if __name__ == '__main__':
    piyo()

Solution (Python):
a = 0
c = 0
for i in range(int(input())):
    b = int(input())
    if b > a:
        c += a
        a = b
    else:
        c += b
c += (a/2)
print (round(c))

Solution (Python):
a = int(input())

b = [int(input()) for i in range(a)]
c = sorted(b)

c[-1] = int(c[-1] / 2)

print(sum(c))

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

Solution (Python):
import numpy as np

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

plist2 = np.array(plist)

tf = np.ones(N,dtype='bool')   

tf[plist.index(max(plist))] = False

print(int(sum(plist2[tf]) + max(plist)/2))

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

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

Solution (Python):
n = int(input())
p = [int(input()) for j in range(n)]

m = max(p)
total = 0
for i in p:
    total += i

print(int(total-m/2))

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

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

P.sort()
res = sum(P[0:N-1]) + P[-1] // 2
print(res)

Solution (Python):
n = int(input())
p = []
for i in range(n):
    p.append(int(input()))
p.sort()
p.reverse()
ans = 0
for i in range(n):
    if i == 0:
        ans = p[i]/2
    else:
        ans += p[i]
if ans - int(ans) != 0:
    print(ans)
else :
    print(int(ans))

Solution (Python):
N = int(input())

kakaku = [int(input()) for _ in range(N)]
total = int(sum(kakaku) - (max(kakaku) / 2))
print(total)

Solution (Python):
str = input()

list=[]
for i in range (int(str)):
    teika = int(input())
    list.append(teika)
    waribiki=max(list)
    
    goukei=sum(list)+waribiki/2-waribiki
print(int(goukei))

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

Solution (Python):
N = int(input())
P = [int(input()) for n in range(N)]

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

Solution (Python):



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


if __name__ == '__main__':
    main()

Solution (Python):
N = int(input())
p = [int(input()) for _ in range(N)]
print(-max(p)//2+sum(p))

Solution (Python):
N = int(input())
p_array = []
price_sum = 0
price_max = 0
for _ in range(N):
    price = int(input())
    
    price_sum += price
    
    price_max = max(price, price_max)

print(price_sum - price_max//2)

Solution (Python):
N = int(input())
p_array = []
for _ in range(N):
  price = int(input())
  p_array.append(price)


price_sum = sum(p_array)

discount = max(p_array)//2

print(price_sum - discount)

Solution (Python):
N = int(input())
pList = []
for i in range(N):
  pList.append(int(input()))
Max = max(pList)
print(sum(pList) - (Max // 2))

Solution (Python):
import numpy as np

n=int(input())
a=[]
for i in range(n):
    a.append(int(input()))
a.sort()
ans=int(0)
for i in range(n-1):
    ans = ans + a[i]
ans = ans + a[-1]/2
print(int(ans))

Solution (Python):
n=int(input())
a=[]
for i in range(n):
    a.append(int(input()))
a.sort()
ans=int(0)
for i in range(n-1):
    ans = ans + a[i]
ans = ans + a[-1]/2
print(int(ans))

Solution (Python):

n = int(input())
p_array = []
for _ in range(n):
  element = int(input())
  p_array.append(element)

price_sum = sum(p_array)
discount = max(p_array)//2

print(price_sum - discount)

Solution (Python):
N=int(input())
list_1=[]
for i in range(N):
  list_1.append(int(input()))
print(int(sum(list_1)-max(list_1)+max(list_1)/2))

Solution (Python):
N = int(input())
p = [int(input()) for x in range(N)]
print(int(sum(p)-max(p)/2))

Solution (Python):
import numpy as np

N = int(input())
childs = np.array([int(input()) for _ in range(N)])
max_num = 0
discount_index = 0

for x in range(len(childs)):
    if max_num < childs[x]:
        max_num = childs[x]
        discount_index = x

childs[discount_index] = int(childs[discount_index]/2)


print(childs.sum())

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

Solution (Python):
import math,string,itertools,fractions,heapq,collections,re,array,bisect,sys,random,time,copy,functools

sys.setrecursionlimit(10**7)
inf = 10**20
eps = 1.0 / 10**10
mod = 10**9+7
dd = [(-1,0),(0,1),(1,0),(0,-1)]
ddn = [(-1,0),(-1,1),(0,1),(1,1),(1,0),(1,-1),(0,-1),(-1,-1)]

def LI(): return [int(x) for x in sys.stdin.readline().split()]
def LI_(): return [int(x)-1 for x in sys.stdin.readline().split()]
def LF(): return [float(x) for x in sys.stdin.readline().split()]
def LS(): return sys.stdin.readline().split()
def I(): return int(sys.stdin.readline())
def F(): return float(sys.stdin.readline())
def S(): return input()
def pf(s): return print(s, flush=True)


def main():
    n = I()
    a = [I() for _ in range(n)]
    r = sum(a)
    r -= max(a) // 2

    return r


print(main())

Solution (Python):
N = int(input())
p = [0 for _ in range(N)]
for i in range(N):
    p[i] = int(input())
print(sum(p) - max(p) // 2)

Solution (Python):
n = int(input())
p = sorted([int(input()) for i in range(n)])
p[-1] = p[-1] // 2
print(sum(p))

Solution (Python):
a = int(input())
count = 0
m = 0
for i in range(a):
    l = int(input())
    count += l
    if m < l:
        m = l
print(count - m // 2)

Solution (Python):
a = [int(input()) for _ in range(int(input()))]
print(int(sum(a) - max(a)/2))

Solution (Python):
def main():
    n = int(input())
    ps = [int(input()) for _ in range(n)]
    print(sum(ps) - max(ps) // 2)


if __name__ == '__main__':
    main()

Solution (Python):






"""問題文

とある世界では、今日はクリスマスイブの前日です。

高羽氏は、デパートで N
個の品物を買おうとしています。i 個目の品物 (1≤i≤N) の定価は pi

円です。

彼は割引券を持っており、N
個のうち最も定価が高い品物 1 個を定価の半額で買うことができます。残りの N−1

個の品物に対しては定価を支払います。支払金額は合計でいくらになるでしょうか？
制約

    2≤N≤10

100≤pi≤10000
pi
は偶数である。"""





N=int(input())

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


p.sort(reverse=True)

p[0]=p[0]/2

tot=0
for i in p:
    tot=tot+i
    
print(int(tot))

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

Solution (Python):
n = int(input())
l = sorted([int(input()) for i in range(n)], reverse=True)
l[0] = l[0] // 2
print(sum(l))

Solution (Python):


n = int(input())

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

p_max_half = max(p)/2
p_max_index = p.index(max(p))

p_sum = sum(p)

print(int(p_sum-p_max_half))

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

Solution (Python):
N = int(input())
p = sorted([int(input()) for _ in range(N)])
print(sum(p[:-1]) + (p[-1] // 2))

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

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

Solution (Python):
a = []
for i in range(int(input())):
    a.append(int(input()))
a.sort()
print(sum(a)-a[-1]//2)

Solution (Python):
import numpy as np
N = int(input())

e = [0] * (N+1)

for i in range(1, N+1):
    e[i] = int(input())

print(np.sum(np.array(e))-int(np.max(np.array(e))/2))

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

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

Solution (Python):
n = int(input())
l = []
sum = 0
for i in range (0,n) :
    x=int(input())
    l.append(x)
    sum+=x
l.sort()
sum-=l[n-1]//2
print(int(sum))

Solution (Python):
N=input()
P=[]
for i in range(N):
    P.append(input())
P.sort()
print sum(P[i] for i in range(len(P)-1))+P[-1]/2

Solution (Python):
N = int(input())
p = []
for i in range(N):
    p.append(int(input()))
p.sort(reverse=True)
p[0] = int(p[0]/2)
result = 0
for i in p:
    result += i
print(result)

Solution (Python):
import numpy as np
n = int(input())
item = np.array([int(input()) for i in range(n)])

print(int(item.sum()-item.max()/2))

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

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

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

Solution (Python):
N = int(input())
p = list(map(int, [input() for i in range(N)]))

sum_a=0
max_a=0
for a in p:
    sum_a+=a
    if max_a<a:
        max_a=a
        
sum_a-=max_a/2
print(int(sum_a))

Solution (Python):
N = int(input())
p_list = [None] * N
for n in range(N):
    p_list[n] = int(input())

max_price = max(p_list)
p_list[p_list.index(max_price)] = max_price // 2
print(sum(p_list))

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

Solution (Python):
n = int(input())
a = []
for i in range(n):
	a.append(int(input()))
b = sorted(a)
sum = 0
for j in range(n-1):
   	sum += b[j]
sum += b[n-1]//2
print(sum)

Solution (Python):
n=int(input())
a=[0]*n
kei=0
for i in range(0,n,1):
    a[i]=int(input())
    kei=kei+a[i]

a.sort(reverse=True)
kei=kei-a[0]//2
print(kei)

Solution (Python):

from sys import stdin

s_in = lambda: stdin.readline()[:-1]  
d_in = lambda: int(stdin.readline())  
ds_in = lambda: list(map(int, stdin.readline().split()))  


N = d_in()
cost = []
for _ in range(N):
    cost.append(d_in())

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

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

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

Solution (Python):
N = int(input())
p = []
for i in range(N):
    p_i = int(input())
    p.append(p_i)
  
p[p.index(max(p))] *= 1/2
print(int(sum(p)))

Solution (Python):
N = int(input())
sum = 0
max = 0
for _ in range(N):
    p = int(input())
    sum += p
    max = p if p > max else max

print(sum - max // 2)

Solution (Python):
n = int(input())
p = [0 for i in range(n)]
for i in range(n):
    p[i] = int(input())
p2 = sorted(p)
print(int(sum(p2)-p2[n-1]*0.5))

Solution (Python):
a =int(input())
m,n =0,0
for i in range(a):
  p=int(input())
  n += p
  m=max(m,p)
a=int(n-m/2)
print(a)

Solution (Python):
N = int(input())

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

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

Solution (Python):
n = int(input())
num_list = []
for i in range(n):
  num_list.append(int(input()))

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

Solution (Python):
N = int(input())
sm,mx = 0,0
for i in range(N):
  P = int(input())
  sm += P
  mx = max(mx, P)

a = int(sm - mx / 2)
print(a)

Solution (Python):
N = int(raw_input())
price = []
for i in range(N):
  price.append(int(raw_input()))
  
print sum(price) - max(price)/2

Solution (Python):
n = int(input())
p_list = [int(input()) for p in range(n)]

max_p = max(p_list) 
p_list.remove(max_p)

print(int(sum(p_list) + max_p / 2))

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

Solution (Python):
total = int(input())
price = []
for i in range(total):
    price.append(int(input()))

max_price = max(price)

print(int(sum(price) - max_price/2))

Solution (Python):
N = int(input())
P = [int(input()) for _ in range (N)]
P.sort()
Sum_price = int(sum(P) - P[len(P)-1]/2)
print(Sum_price)

Solution (Python):
from sys import stdin


def main():
    N = int(stdin.readline().rstrip())
    p = [int(stdin.readline().rstrip()) for _ in range(N)]
    p = sorted(p)
    print(sum(p[:-1]) + p[-1] // 2)


if __name__ == "__main__":
    main()

Solution (Python):
N = int(input())

p = []
ans = 0

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

p.sort()

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

print(ans + p[N-1] // 2)

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

m = int(max(p) / 2)
ans = sum(p)
print(ans - m)

Solution (Python):
N = int(input())
L = []
for i in range(N):
    L.append(int(input()))

res = sum(L) - max(L)//2
print(res)

Solution (Python):
N = int(input())

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

max = max(P)


dif = int(0.5*max)
print(sum(P)-dif)

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

Solution (Python):
N = int(input())
sum = 0
max = -1
for i in range(N):
    price = int(input())
    sum += price
    if price > max:
        max = price
print(int(sum-max/2))

Solution (Python):
a = int(input())
b = []
for i in range(a):
    c = int(input())
    b.append(c)
d = max(b)/2
e = sum(b)
print(int(e - d))

Solution (Python):
n = int(input())
k = []
for i in range(n):
  a = int(input())
  k.append(a)
b = max(k)/2
k.remove(max(k))
k.append(b)
print(int(sum(k)))

Solution (Python):
N = int(input())
S = [int(input()) for _ in range(N)]
S.sort(reverse=True)
S[0] = S[0] / 2
print(int(sum(S)))

Solution (Python):
n = int(input())
prices = []
for i in range(0,n):
    prices.append(int(input()))
    
coupon = max(prices) // 2
    
total = sum(prices) - coupon
print(total)

Solution (Python):
n=int(input())
p = [int(input()) for x in range(n)]
p.append(max(p)/2)
p.remove(max(p))
print(int(sum(p)))

Solution (Python):
N = int(input())
p = list()
for x in range(0,N):
    p.append(int(input()))
p_sorted = sorted(p)
p_sorted[N-1] = p_sorted[N-1]//2
X = 0
for y in range(0,N):
    X += p_sorted[y]
print(X)

Solution (Python):
n=int(input())
a=[int(input()) for _ in [0]*n]
print(sum(a)-max(a)//2)

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

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

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

ma = max(p)
for i in range(N):
    if p[i] == ma:
        p[i] = ma/2
        break

print(int(sum(p)))

Solution (Python):
import math
N=int(input())
p=[int(input()) for i in range(N)]
po=sum(p)-max(p)/2
print(math.floor(po))

Solution (Python):
n = int(input())
val = [int(input()) for i in range(n)]
max_val = max(val)
val.remove(max_val)
print(int(sum(val) + (max_val // 2)))

Solution (Python):
n = int(input())
p = [int(input()) for _ in range(n)]
print(sum(p)-max(p)//2)

Solution (Python):
n = int(input()) 
t = [int(input()) for i in range(n)] 
kk = max(t)
print(int(sum(t)-kk/2))

Solution (Python):
num = int(input())

l = []

for i in range(num):
    price = int(input())
    l.append(price)

l.sort(reverse = True)
l[0] = int(l[0] / 2)
print(sum(l))

Solution (Python):


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

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

Solution (Python):




import sys


n = int(input())
ps = [int(input()) for l in range(n)]
ps.sort()

sum_p  = sum(ps) - int(ps[-1] / 2)
print(sum_p)

Solution (Python):
N = int(input())
item_prices = [int(input()) for _ in range(N)]
print(sum(item_prices) - max(item_prices) // 2)

Solution (Python):
N=int(input())
li=[]

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

x=max(li)
total=sum(li)-x//2

print(total)

Solution (Python):
N = int(input())
a = []
for i in range(N):
    a.append(int(input()))

a.sort()

print(int(sum(a[:N-1])+a[N-1]/2))

Solution (Python):
al = [int(input()) for _ in range(int(input()))]
print(sum(al) - max(al) // 2)

Solution (Python):
N = int(input())
L = []
for i in range(N):
    p_i = int(input())
    L.append(p_i)
k = L.index(max(L))
m = max(L) // 2
del L[k]
print(sum(L)+m)

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

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

Solution (Python):
N=input()
p=[]
total=0
flg=0
for i in range(N):
	p.append(input())
for i in range(N):
  if max(p) == p[i] and flg==0:
    flg=1
    total += p[i]/2
  else:
    total += p[i]
print total

Solution (Python):
n = int(input())
highest_price = 0
sum = 0
for i in range(n):
    product = int(input())
    if highest_price < product:
        sum += highest_price/2
        highest_price = product
        sum += highest_price/2
    else:
        sum += product
print(int(sum))

Solution (Python):


N=int(input())

temp=0
out_sum=0
for i in range(N):
    present=int(input())
    if temp < present:
        temp=present
    out_sum+=present
        
out_sum-=temp/2

print(int(out_sum))

Solution (Python):
n = int(raw_input())

arr = []
for i in xrange(n):
    a = int(raw_input())
    arr.append(a)

max = -1
sum = 0
for i in xrange(n):
    if arr[i] > max:
        max = arr[i]
    sum += arr[i]

sum -= max/2

print sum

Solution (Python):
N=int(input())
cnt=0
ans=0
max=0
while cnt<N:
  cnt+=1
  p=int(input())
  ans += p
  if p>max:
    max=p
ans-=int(max/2)
print(ans)

Solution (Python):
N=int(input())
p=[]
i=1
while i<=N:
    p.append(int(input()))
    i=i+1

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

Solution (Python):
N = int(input())

P = map(int, [ input() for _ in range(N) ])
P = list(P)
print (int(sum(P) - max(P) / 2.0 ))

Solution (Python):
n = int(input())
prices = sorted([int(input()) for _ in range(n)])
print(sum(prices[:-1]) + (prices[-1] // 2))

Solution (Python):
Num = int(input())
list = []
for i in range(0,Num):
    list.append(int(input()))
list.sort()
list[Num-1] = list[Num-1] / 2
print(int(sum(list)))

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

num = p.index(max(p))
p[num] = p[num] // 2

print(sum(p))

Solution (Python):
N = int(input())
li = [int(input()) for i in range(N)]
x = max(li)

for i in range(N):
    if li[i] == x:
        li[i] = int(x / 2)
        break

print(sum(li))

Solution (Python):
N = int(input())

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

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

print(sum(value))

Solution (Python):
n = int(input())
p = [int(input()) for i in range(n)]
p.sort()

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

Solution (Python):
n = int(input())
values = []

values = [int(input()) for _ in range(n)]
boro = max(values)
index = values.index(max(values))
del values[index]
boro = int(boro / 2.0)
values.append(boro)
sum = 0

for i in values:
    sum += i

print(sum)

Solution (Python):

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

Solution (Python):
N = int(input())
List = list(map(int,[input() for _ in range(N)]))
Max = max(List)
print(int(sum(List)-max(List)/2))

Solution (Python):
n=range(int(input()))
a=[int(input()) for i in n]
print(sum(a)-max(a)//2)

Solution (Python):
N=int(input())
goods=[]
for i in range(N):
    goods.append(int(input()))
expensive=max(goods)
sum=expensive/2
goods.remove(max(goods))
for i in range(N-1):
    sum+=goods[i]
print(int(sum))

Solution (Python):
N = int(input())
sum = 0
value = []
mv = 0
mn = 0
for i in range(N):
    val = int(input())
    value.append(val)
    if value[i] > mv:
        mv = value[i]
        mn = i

for i in range(N):
    if i == mn:
        sum += value[i] / 2
    else:
        sum += value[i]

print(int(sum))

Solution (Python):


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

aN.sort(reverse=True)
aN[0] //= 2
print(sum(aN))

Solution (Python):
N = int(input())
p = [int(input()) for i in range(N)]
max_p = int(max(p)/2) 
p.remove(max(p))
print(sum(p) + max_p)

Solution (Python):



def main():
    n = int(input())

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

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


if __name__ == '__main__':
    main()

Solution (Python):
from sys import stdin
a = stdin.readline()
w=int(a)
j=1
sumvalue=0
maxvalue=0
w2=[]
while j<=w:
    z = stdin.readline().rstrip('\n')
    sumvalue+=int(z)
    maxvalue=max(maxvalue,int(z))
    j+=1
print(sumvalue-int(maxvalue/2))

Solution (Python):
N = int(input())
sum = 0
P = []
for i in range(N):
    P.append(int(input()))
    sum += P[i]

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

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

l.sort(reverse=True)
print(int(sum(l)-(l[0]/2)))

Solution (Python):
n=int(input())
s=[]
ans=0
for i in range(n):
    s.append(int(input()))
s.sort()

for i in range(n-1):
    ans+=s[i]
ans+=int(s[n-1]/2)
print(ans)

Solution (Python):
N=int(input())
p=[int(input())for _ in[0]*N]
print(sum(p)-max(p)//2)

Solution (Python):
N=int(input())
price=[int(input()) for i in range(N)]
price.sort()
print(int(sum(price)-price[-1]+price[-1]/2))

Solution (Python):
N = int(input())

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

s = sum(P)

print(int(s - max(P) // 2))

Solution (Python):
N = int(input())
price_list = []
for i in range(N):
  price_list.append(int(input()))

max_price = max(price_list)
price_list.remove(max_price)
print(int(max_price / 2) + sum(price_list))

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

Solution (Python):

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

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

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

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

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

    p.sort(reverse=True)
    p[0] = int(p[0] / 2)

    print(sum(p))

if __name__ == "__main__":
    main()

Solution (Python):
def main():
    n = int(input())
    prices = []
    for i in range(n):
        p = int(input())
        prices.append(p)
    prices.sort()
    prices[-1] /= 2
    print(int(sum(prices)))

if __name__ == "__main__":
    main()

Solution (Python):
n=int(input())
a=[]
b=0
for i in range(n):
    c=int(input())
    a.append(c)
for u in a:
    b+=u
print(b-(max(a)//2))

Solution (Python):



def main():
    n = int(input())
    p = sorted([int(input()) for _ in range(n)])

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


if __name__ == '__main__':
    main()

Solution (Python):



def main():
    n = int(input())
    p = sorted([int(input()) for _ in range(n)])
    ans = 0

    for index, pi in enumerate(p, 1):
        if index == n:
            ans += int(pi / 2)
        else:
            ans += pi

    print(ans)


if __name__ == '__main__':
    main()

Solution (Python):
list=[]
n = int(input())
for i in range(n):
    list.append(int(input()))
list.sort(reverse=True)
list[0] = list[0] / 2
sum = 0
for i in range(len(list)):
    sum = sum + list[i]
print(int(sum))

Solution (Python):
n=int(input())
lst=[int(input())for i in range(n)]
lst.sort(reverse=True)
lst[0]//=2
print(sum(lst))

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

Solution (Python):


from collections import deque
import itertools as it
import sys
import math

sys.setrecursionlimit(1000000)

INF = 10 ** 18
MOD = 10 ** 9 + 7

N = input()

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

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

Solution (Python):
n = int(input())
sum =0
max =0
index=0
while index < n:
    p = int(input())
    sum+=p
    if p > max:
        max = p
    else:
        pass
    index+=1
  
print(sum - max//2)

Solution (Python):



n=int(input())
p=[] 
sum=0 

for i in range(n):
    p.append(int(input()))
p.sort() 
p[n-1]=int(p[n-1]/2) 
for q in p:
    sum+=q

print(sum)

Solution (Python):
print((lambda p:sum(p) - max(p) // 2)([int(input()) for _ in range(int(input()))]))

Solution (Python):
N = int(input());
p = [];

b = 0;

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


a = max(p);
a /= 2;

b -= a;
print(round(b));

Solution (Python):
N = int(input())
items = []
for i in range(N):
  items.append(int(input()))
sort = sorted(items, reverse=True)
sort[0] = sort[0]/2
print(int(sum(sort)))

Solution (Python):
ans = 0
m = 0
for _ in range(int(input())):
    p = int(input())
    ans += p
    m = max(m,p)
print(ans - m//2)

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

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

xs = sorted(p)
result = sum(xs) - xs[-1] // 2
print(result)

Solution (Python):

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

Solution (Python):
N = int(input())
pi = list(map(lambda x: int(input()), range(N)))

max_pi = max(pi)
sum_pi = int(sum(pi) - max_pi/2)

print(sum_pi)

Solution (Python):
n = int(input())
a = [int(input()) for i in range(n)]

b = max(a)
print(sum(a) - b//2)

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

Solution (Python):
N = int(input())
ma = 0
ans = 0
for i in range(N):
    p = int(input())
    if ma < p/2:
        ma = int(p/2)
    ans += p
else:
    print(ans - ma)

Solution (Python):
n = int(input())
p = [0]*n
for i in range(n):
	p[i] = int(input())

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

Solution (Python):
n = int(input())
arr = []
s = 0
for i in range(n):
    temp = int(input())
    arr.append(temp)
    s += temp
print(int(s - max(arr)/2))

Solution (Python):

N = int(input())

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

p[p.index(max(p))] = max(p) // 2
print(sum(p))

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

Solution (Python):
def solve(string):
    ins = list(map(int, string.split("\n")))[1:]
    ins.sort()
    ins[-1] //= 2
    return str(sum(ins))


if __name__ == '__main__':
    n = int(input())
    ins = [input() for _ in range(n)]
    print(solve("{}\n{}".format(n, "\n".join(ins))))

Solution (Python):
n = int(input())
p = []

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

p.sort()

ans = round(sum(p) - p[-1] / 2)

print(ans)

Solution (Python):



import sys


sys.setrecursionlimit(10 ** 6)

read_single_int = lambda: int(sys.stdin.readline().strip())


def solution(ps: list):
    max_price = max(ps)
    return sum(ps) - max_price//2


def main():
    n = read_single_int()
    ps = []
    for _ in range(n):
        ps.append(read_single_int())
    print(solution(ps))


if __name__ == '__main__':
    main()