Problem:
 Score : 100 points    Problem Statement There are three airports A, B and C, and flights between each pair of airports in both directions.  A one-way flight between airports A and B takes P hours, a one-way flight between airports B and C takes Q hours, and a one-way flight between airports C and A takes R hours.  Consider a route where we start at one of the airports, fly to another airport and then fly to the other airport.  What is the minimum possible sum of the flight times?      Constraints  1 \leq P,Q,R \leq 100  All values in input are integers.         Input Input is given from Standard Input in the following format:  P  Q  R       Output Print the minimum possible sum of the flight times.        Sample Input 1 1 3 4      Sample Output 1 4   The sum of the flight times in the route A \rightarrow B \rightarrow C: 1 + 3 = 4 hours  The sum of the flight times in the route A \rightarrow C \rightarrow C: 4 + 3 = 7 hours  The sum of the flight times in the route B \rightarrow A \rightarrow C: 1 + 4 = 5 hours  The sum of the flight times in the route B \rightarrow C \rightarrow A: 3 + 4 = 7 hours  The sum of the flight times in the route C \rightarrow A \rightarrow B: 4 + 1 = 5 hours  The sum of the flight times in the route C \rightarrow B \rightarrow A: 3 + 1 = 4 hours   The minimum of these is 4 hours.       Sample Input 2 3 2 3      Sample Output 2 5

Solution (Python):
p, q, r = map(int, input().split())
ans = p + q + r - max(p, q, r)

print ( ans)

Solution (Python):
def calc(P,Q,R):
  sum1=P+Q
  sum2=Q+R
  sum3=R+P
  return min(sum1,sum2,sum3)

P,Q,R = map(int,input().split())
print(calc(P,Q,R))

Solution (Python):
import numpy as np
p,q,r = map(int,input().split())
print(p+q+r-np.max([p,q,r]))

Solution (Python):
a,b,c = map(int, input().split())
print(min([a+b,b+c,c+a]))

Solution (Python):
tmp0 = input()
P, Q, R = tmp0.split(" ")
del tmp0
P, Q, R = int(P), int(Q), int(R)
print(min(P+Q, Q+R, R+P))

Solution (Python):
P, Q, R = map(int, input().split())
print(min(P+Q, Q+R, R+P))

Solution (Python):
p, q, r = map(int, input().split())
print(min(p + q, p + r, r + q))

Solution (Python):
a,b,c = map(int,input().split())
print(min(a+b,a+c,b+c))

Solution (Python):
l=sorted(map(int,input().split()), key=int)
print(l[1]+l[0])

Solution (Python):

words = lambda t : list(map(t, input().split()))
pqr = words(int)

pqr.sort()
print(pqr[0] + pqr[1])

Solution (Python):
c=list(map(int, input().split()))
c.remove(max(c))
print(sum(c))

Solution (Python):
a = [int(i) for i in input().split()]
a.sort()
ans = a[0] + a[1]
print(ans)

Solution (Python):
p, q, r = map(int, input().split())
print(min(p+q, min(q+r, r+p)))

Solution (Python):

p = list(map(int,input().split()))
p.sort()
print(p[0]+p[1])

Solution (Python):
p, q, r = map(int, input().split())
print(min(p+q, p+r, q+r))

Solution (Python):
data = list(map(int, input().split()))
data.sort()

print(sum(data[:2]))

Solution (Python):
p, q, r = map(int, input().split())
l = [p+q, q+r, r+p]
print(min(l))

Solution (Python):
PQR = list(map(int,input().split()))
print(sum(sorted(PQR)[:2]))

Solution (Python):
A = list(map(int, input().split()))
A = sorted(A)
print(sum(A[:2]))

Solution (Python):
time=list(map(int,input().split()))

timed=sorted(time)

print(int(timed[0])+int(timed[1]))

Solution (Python):
P, Q, R = map(int, input().split())
print(min(P+Q, Q+R, R+P))

Solution (Python):
lis = list(map(int, input().split()))
print(sum(lis) - max(lis))

Solution (Python):
inp = input().split()
p = int(inp[0])
q = int(inp[1])
r = int(inp[2])

print(p+q+r- max([p,q,r]))

Solution (Python):
X = list(map(int, input().split()))

print(sum(X) - max(X))

Solution (Python):
p,q,r=map(int,input().split())
print(min(p+q,q+r,r+p))

Solution (Python):
print(sum(sorted(list(map(int, input().split())))[:2]))

Solution (Python):
import math
import sys
import numpy
p = list(map(int,input().split()))
ans = sum(p)-max(p)
print(ans)

Solution (Python):
hour = sorted(list(map(int,input().split())))
print(sum(hour[:2]))

Solution (Python):
P,Q,R =map(int,input().split())
print(P+Q+R-max(P,Q,R))

Solution (Python):
p,q,r=map(int,input().split())
print(p+q+r-max(p,q,r))

Solution (Python):
p, q, r = map(int, input().split())
print(p + q + r - max(p, q, r))

Solution (Python):
l = [int(i) for i in input().split()]

l.sort()
print(l[0]+l[1])

Solution (Python):
p,q,r=list(map(int,input().split()))
List=[p+q,p+r,q+r]
print(min(List))

Solution (Python):
a = sorted(map(int, input().split()))
print(a[0]+a[1])

Solution (Python):
dist = list(map(int,input().split()))
dist.sort()
dist2 = dist[:2]
print(sum(dist2))

Solution (Python):
li = list(map(int, input().split()))
li.sort()
print(li[0]+li[1])

Solution (Python):
P, Q, R = map(int, input().split())
print(P+Q+R-max(P,Q,R))

Solution (Python):
a,b,c=map(int,input().split());print(min(a+b,b+c,c+a))

Solution (Python):
P, Q, R = map(int, input().split())
times = [P, Q, R]
from itertools import combinations
 
min_ = 200
for i in combinations(times, r=2):
  j = sum(i)
  if j < min_:
    min_ = j
print(min_)

Solution (Python):

InText = input()

FS = InText.find(" ")

SS = InText.find(" ",FS+1)

P = int(InText[0:FS])
Q = int(InText[FS+1:SS])
R = int(InText[SS+1:])

Airports = [P,Q,R]

Airports.sort()

print(Airports[0]+Airports[1])

Solution (Python):
p,q,r = map(int,input().split())


ABC = p + q
BCA = q + r
CAB = r + p

min = ABC
if min > BCA:
  min = BCA
  
if min > CAB:
  min = CAB

print(min)

Solution (Python):
p_q_r=input().split()
p_q_r=[int(p_q_r[i]) for i in range(3)]
p_q_r.sort()
print(p_q_r[0]+p_q_r[1])

Solution (Python):
P , Q , R = map(int,input().split())
print(min(P+Q,Q+R,P+R))

Solution (Python):
import statistics
root = list(map(int, input().split()))
a = min(root)
b = statistics.median(root)
print(a + b)

Solution (Python):
P,Q,R=map(int,input().split())
ans=[P,Q,R]
ans.sort()
print(ans[0]+ans[1])

Solution (Python):
a=list(map(int,input().split()))
a.sort()
print(a[0]+a[1])

Solution (Python):
p, q, r = input().split()
p = int(p)
q = int(q)
r = int(r)
print( p+q+r-max(p,q,r) )

Solution (Python):


def main():
	flight_time = sorted(map(int, input().split()))
	print(flight_time[0] + flight_time[1])

if __name__ == "__main__":
	main()

Solution (Python):
p, q, r = map(int, input().split())

ans = p + q + r - max(p, q, r)

print(ans)

Solution (Python):
a=list(map(int,input().split()))
b=[a[0]+a[1],a[0]+a[2],a[1]+a[2]]
print(min(b))

Solution (Python):
a=list(map(int,input().split()))
a.sort()
print(a[0]+a[1])

Solution (Python):

AIR_PORTS = ['A', 'B', 'C']


def get_input():
    PandQandR = input().split(" ")
    P = int(PandQandR[0])
    Q = int(PandQandR[1])
    R = int(PandQandR[2])
    return P, Q, R


def calc_flight_time(flight_time_list):
    min = 500
    for i, time_1 in enumerate(flight_time_list):
        for j, time_2 in enumerate(flight_time_list):
            if i == j:
                continue
            result_time = time_1 + time_2
            if min > result_time:
                min = result_time
    return min


def main():
    P, Q, R = get_input()
    flight_time_list = [P, Q, R]
    result_time = calc_flight_time(flight_time_list)
    print(result_time)


if __name__ == '__main__':
    main()

Solution (Python):
P,Q,R = map(int,input().split())
PQ = P + Q
PR = P + R
QR = Q + R
t = [PQ, PR, QR]
print(min(t))

Solution (Python):



P_Q_R = input()

P = int(P_Q_R.split(" ")[0])
Q = int(P_Q_R.split(" ")[1])
R = int(P_Q_R.split(" ")[2])

PQR =[P, Q, R]

import numpy as np

print(np.sum(PQR) - np.max(PQR))

Solution (Python):
pqr = list(map(int, input().split()))
pqr.sort()

print(sum(pqr[0:2:]))

Solution (Python):
a = list(map(int,input().split()))
a.sort()
print(a[0]+a[1])

Solution (Python):
a, b, c = map(int, input().split());
print(min(a+b, b+c, c+a));

Solution (Python):
p,q,r = map(int,input().split())
print(min(p+q, q+r, r+p))

Solution (Python):
air = input().split()
air = [int(i) for i in air]
air_min = min([air[0] + air[1], air[1] + air[2], air[0] + air[2]])
print(air_min)

Solution (Python):
p,q,r = map(int, input().split())
print((p+q+r)-max([p,q,r]))

Solution (Python):
a=list(map(int,input().split()))
print(sum(a)-max(a))

Solution (Python):
a=list(map(int,input().split()))
print(min(a[0]+a[1],a[1]+a[2],a[2]+a[0],))

Solution (Python):
P,Q,R=map(int,input().split())




list=[]
list.append(P+Q)
list.append(R+Q)
list.append(P+R)
list.append(Q+R)
list.append(R+P)
list.append(Q+P)


a=sorted(list)

print(a[0])

Solution (Python):
l=list(map(int,input().split()))

m=sorted(l)[:2]

n=sum(m)
print(n)

Solution (Python):
import sys
input = sys.stdin.readline

L = list(map(int, input().split()))
L.sort()
print(L[0] + L[1])

Solution (Python):
P, Q, R = map(int, input().split())
print(P + Q + R - max(P, Q, R))

Solution (Python):
p,q,r = map(int,input().split(" "))

tmp = [p,q,r]

tmp.sort()

print(tmp[0] + tmp[1])

Solution (Python):
l=list(map(int,input().split()))
m=sorted(l)[:2]
n=sum(m)
print(n)

Solution (Python):
lst_A = input().split()

for i in range(len(lst_A)):
	lst_A[i] = int(lst_A[i])
  
lst_A.sort()

ans = lst_A[0] + lst_A[1]

print(ans)

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

sys.setrecursionlimit(10**7)
inf = 10**20
eps = 1.0 / 10**10
mod = 998244353
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 list(map(int, sys.stdin.readline().split()))
def LLI(): return [list(map(int, l.split())) for l in sys.stdin.readlines()]
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 pe(s): return print(str(s), file=sys.stderr)
def JA(a, sep): return sep.join(map(str, a))


def main():
    a = LI()

    return sum(a) - max(a)


print(main())

Solution (Python):
P, Q, R = map(int, input().split())
print(sum(sorted([P, Q, R])[:2]))

Solution (Python):
pqr = list(map(int, input().split()))
pqr.sort()
print(pqr[0] + pqr[1])

Solution (Python):
P, Q, R = map(int, input().split())
print(sorted([P, Q, R])[0] + sorted([P, Q, R])[1])

Solution (Python):
sum_hour=[]
ans_hour=0
P,Q,R= map(int, input().split())

sum_hour.append(P+Q)
sum_hour.append(P+R)
sum_hour.append(R+Q)
ans_hour=min(sum_hour)
print(ans_hour)

Solution (Python):
pqr = input().split()

abc = int(pqr[0]) + int(pqr[1])
bca = int(pqr[1]) + int(pqr[2])
cab = int(pqr[2]) + int(pqr[0])

print(min(abc, bca, cab))

Solution (Python):
import bisect

def main():
    data = list(map(int, input().split()))
    print(sum(data) - max(data))




if __name__ == '__main__':
    main()

Solution (Python):
P,Q,R=map(int,input().split())
a=min(P+Q,P+R,Q+R)
print(a)

Solution (Python):
p,q,r=map(int,input().split())
print(p+q+r-max(p,q,r))

Solution (Python):
P,Q,R=input().split()
P,Q,R=int(P),int(Q),int(R)
n=[P,Q,R]
lst=sorted(n)
print(sum(lst[0:2]))

Solution (Python):
P, Q, R = list(map(int, input().split()))
print(min(P+Q,Q+R,R+P))

Solution (Python):
def smaller(x, y):
	if x < y: return x
	return y

P, Q, R = map(int, input().split())
print(smaller(P+Q, smaller(Q+R, R+P)))

Solution (Python):
P, Q, R = map(int, input().split(" "))
print(min(min(P + Q, Q + R), P + R))

Solution (Python):
li = list(map(int,input().split()))
li.sort()
print(li[0]+li[1])

Solution (Python):
p, q, r = map(int, input().split())
print(min(p+q,q+r,r+p))

Solution (Python):
p,q,r = map(int, input().split())
print(min(p+q, q+r, r+p))

Solution (Python):
def airplane(P: int, Q: int, R: int)->int:
    return min(P+Q, Q+R, R+P)


if __name__ == "__main__":
    P, Q, R = map(int, input().split())

    ans = airplane(P, Q, R)
    print(ans)

Solution (Python):
l = list(map(int, input().split()))
print(sum(l) - max(l))

Solution (Python):
l = list(map(int,input().split()))
print(sum(l)-max(l))

Solution (Python):
a = list(map(int, input().split()))

print(sum(a) - max(a))

Solution (Python):
l = list(map(int,input().split()))
print(sum(l)-max(l))

Solution (Python):
p,q,r = map(int,input().split())

print(min(p+q,q+r,r+p))

Solution (Python):


if __name__ == '__main__':
     air = list(map(int, input().split()))
     air.remove(max(air))
     print(sum(air))

Solution (Python):
l=list(map(int,input().split()))
m=sorted(l)
n=sum(m[:2])
print(n)

Solution (Python):
l = sorted([int(i) for i in input().split()])
print(l[0] + l[1])

Solution (Python):
a = list(map(int, input().split()))

print(sum(a) - max(a))

Solution (Python):
print((lambda a:sum(a)-max(a))(list(map(int,input().split()))))

Solution (Python):
print(sum(sorted(map(int,input().split()))[:2]))

Solution (Python):
p,q,r=map(int,input().split())

print(min(p+q,q+r,r+p))

Solution (Python):
a,b,c=map(int,input().split())
print(min(a+b,b+c,c+a))

Solution (Python):

def nyan(f=lambda x: x): return map(f,input().split())

a,b,c = nyan(int)
print(min(a+b,b+c,c+a))

Solution (Python):
P, Q, R = map(int, input().split())
print(min(P + Q, Q + R, P + R))

Solution (Python):
x = [int(i) for i in input().split()]
x.sort()
print(x[0]+x[1])

Solution (Python):
pqr = input().split()
for i in range(3):
     pqr[i] = int(pqr[i])
a = min(pqr[0]+pqr[1], pqr[1]+pqr[2], pqr[2]+pqr[0])
print(a)

Solution (Python):
times = list(map(int, input().split()))
print(sum(times) - max(times))

Solution (Python):
a,b,c = map(int,input().split())
print(min(a+b,b+c,c+a))

Solution (Python):
P, Q, R = map(int, input().split())

ans = min([P + Q, P + R, Q + R])
print(ans)

Solution (Python):

P,Q,R = map(int, input().split())

print(P+Q+R-max(P,Q,R))

Solution (Python):
P,Q,R=map(int,input().split())
print(min(P+Q,Q+R,P+R))

Solution (Python):
P, Q, R = (int(i) for i in input().split())

ans = P+Q+R -max(P,Q,R)

print(ans)

Solution (Python):
p, q, r = [int(elem) for elem in input().split()]
lst = [p, q, r]
lst = sorted(lst)
print(sum(lst[0:2]))

Solution (Python):
p, q, r = map(int, input().split())
print(min(p+q, q+r, r+p))

Solution (Python):
X = [int(_) for _ in input().split()]

print(sum(X) - max(X))

Solution (Python):
lis = list(map(int, input().split()))

m = sum(lis)
l = len(lis)

for j in range(l):
  for k in range(l):
    if k <= j:
      continue
    tmp = lis[j]+lis[k]
    if tmp < m:
      m = tmp
      
print(m)

Solution (Python):
p,q,r = map(int,input().split())
ans = min(p+q,p+r,q+r)
print(ans)

Solution (Python):



def main():
    p, q, r = map(int, input().split())
    print(p + q + r - max(p, q, r))


if __name__ == '__main__':
    main()

Solution (Python):
P,Q,R = input().split()






min = min(int(P)+int(Q), int(P)+int(R), int(Q)+int(R))

print(min)

Solution (Python):
P,Q,R=map(int,input().split())

a = P + Q
b = Q + R
c = R + P

print(min(a,b,c))

Solution (Python):
p,q,r = map(int, input().split())
print(p+q+r-max(p,q,r))

Solution (Python):
P, Q, R = map(int, input().split())
m = min(P+Q, Q+R, R+P)
print(m)

Solution (Python):


import sys
import copy

sys.setrecursionlimit(1000000)





a = list(map(int, input().split()))

print(sum(a) - max(a))

Solution (Python):
P,Q,R = map(int, input().split())
if P+Q<=Q+R:
    if P+Q<=R+P:
        print(P+Q)
    else:
        print(R+P)
elif Q+R<P+Q:
    if Q+R<=R+P:
        print(Q+R)
    else:
        print(R+P)

Solution (Python):
P,Q,R=map(int,input().split())

a=[P+Q,Q+R,R+P]

print(min(a))

Solution (Python):
import sys
input = sys.stdin.readline

pqr = list(map(int, input().split()))
pqr.sort()
print(pqr[0]+pqr[1])

Solution (Python):
p,q,r = map(int, input().split())
print(min(p+q,q+r,r+p))

Solution (Python):
P,Q,R=map(int,input().split())
a=[P+Q,Q+R,R+P]
print(min(a))

Solution (Python):
p, q, r = [int(i) for i in input().split()]
print(p+q+r-max(p,q,r))

Solution (Python):
a,b,c=map(int,input().split())
x=max(a,max(b,c))
print(a+b+c-x)

Solution (Python):
import sys
input = sys.stdin.readline

ts = [int(i) for i in input().split(" ")]

ts.sort()
print(ts[0]+ts[1])

Solution (Python):
import itertools
P, Q, R = [int(i) for i in input().split()]








print(min([sum(i) for i in (list(itertools.combinations([P, Q, R],2)))]))

Solution (Python):
P, Q, R = map(int, input().split())

ans = P + Q
ans = min(ans, R + Q)
ans = min(ans, P + R)
ans = min(ans, Q + R)
ans = min(ans, Q + P)
ans = min(ans, R + P)

print("{}".format(ans))

Solution (Python):
da=list(map(int,input().split()))
x=-max(da)
for i in da:
    x+=i
print(x)

Solution (Python):
p, q, r = map(int, raw_input().split(" "))

ans = p + q + r - max(p, q, r)
print(ans)

Solution (Python):

n = list(map(int, input().split()))

a = n[0] + n[1]
b = n[0] + n[2]
c = n[1] + n[2]

print(min(a,b,c))

Solution (Python):
a,b,c = map(int, input().split())
print(min(a+b,b+c,c+a))

Solution (Python):
print(sum(sorted(list(map(int, raw_input().split())))[:2]))

Solution (Python):
dists = sorted(list(map(int, input().split())))

dists.pop()
print(sum(dists))

Solution (Python):
T=list(map(int,input().split()))
T.sort()
print(T[0]+T[1])

Solution (Python):
print(sum(sorted(map(int,input().split()))[:2]))

Solution (Python):
def spaceinput():
    return list(map(int,input().split(" ")))


p,q,r=spaceinput()

print(min(p+q,q+r,r+p))

Solution (Python):
import math, string, itertools, fractions, heapq, collections, re, array, bisect, copy, functools, random
import sys
from collections import deque, defaultdict, Counter; from heapq import heappush, heappop
from itertools import permutations, combinations, product, accumulate, groupby
from bisect import bisect_left, bisect_right, insort_left, insort_right
from operator import itemgetter as ig
sys.setrecursionlimit(10 ** 7)
inf = 10 ** 20; INF = float("INF"); ans = 0; tmp = 0; ansli = []; tmpli = []; candili = []
eps = 1.0 / 10 ** 10; mod = 10 ** 9 + 7
dd = [(-1, 0), (0, 1), (1, 0), (0, -1)]; ddn = dd + [(-1, 1), (1, 1), (1, -1), (-1, -1)]; ddn9 = ddn + [(0, 0)]
"""for dx, dy in dd:
        nx = j + dx; ny = i + dy
            if 0 <= nx < w and 0 <= ny < h:"""
def wi(): return list(map(int, sys.stdin.readline().split()))
def wip(): return [int(x) - 1 for x in sys.stdin.readline().split()]
def ws(): return sys.stdin.readline().split()
def i(): return int(sys.stdin.readline())
def s(): return input()
def hi(n): return [i() for _ in range(n)]
def hs(n): return [s() for _ in range(n)]
def mi(n): return [wi() for _ in range(n)]
def mip(n): return [wip() for _ in range(n)]
def ms(n): return [ws() for _ in range(n)]

p, q, r = wi()

print(min(p + q, r + q, p + r))

Solution (Python):
i = list(map(int, input().split()))
i.sort()
print(i[0]+i[1])

Solution (Python):

p = [int(i) for i in input().split()]
p.sort()
print(p[0]+p[1])

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

sys.setrecursionlimit(10**7)
inf=10**20
mod=10**9+7

def LI(): return list(map(int,input().split()))
def I(): return int(input())
def LS(): return input().split()
def S(): return input()

def main():
  a,b,c=LI()

  return min(a+b,a+c,b+c)

print(main())

Solution (Python):
pqr=list(map(int,input().split()))
pqr.sort()
print(pqr[0]+pqr[1])

Solution (Python):
P = list(map(int,input().split()))
P.sort()
print(P[0]+P[1])

Solution (Python):
p,q,r = map(int,input().split())
print(min(p+q,q+r,r+p))

Solution (Python):
p,q,r = map(int,input().split())
m = p + q + r
a = p + q
b = r + q
c = p + r
if a < m:
    m = a
if b < m:
    m = b
if c < m:
    m = c

print(m)

Solution (Python):
P, Q, R = map(int, input().split())

A = P+Q
B = R+Q
C = P+R
D = Q+R
E = Q+P
F = R+P

num = [A, B, C, D, E, F]
print(min(num))

Solution (Python):
from collections import Counter as D, defaultdict as dd
from math import factorial as ft, ceil as aron, log
from fractions import gcd as pg 
from bisect import insort as ins, bisect_left as bl, bisect_right as br
import sys


raw_input=sys.stdin.readline

f1=lambda : map(int,raw_input().split())
f2=lambda : map(int,list(raw_input()))
f3=lambda : int(raw_input())
f4=lambda : raw_input().rstrip()
f5=lambda : raw_input().split()


def main():
    a=f1()
    a.sort()
    print sum(a[:2])
    


if __name__ == '__main__':
	main()

Solution (Python):
P, Q,R = map(int, input().split())
print("{}".format(min([P+Q,Q+R,R+P])))

Solution (Python):






lis=list(map(int,input().split()))

ans=min(lis[0]+lis[1],lis[1]+lis[2],lis[2]+lis[0])

print(ans)

Solution (Python):
p, q, r = map(int, input().split())
print(p+q+r-max(p,q,r))

Solution (Python):
p,q,r = map(int, input().split())
print(min(p+q,q+r,r+p))

Solution (Python):
PQR = [int(pqr) for pqr in input().split()]
PQR.sort()
print(PQR[0] + PQR[1])

Solution (Python):
time=list(map(int,input().split()))

ans=[]
for i in range(len(time)):
    for j in range(i+1,len(time)):
        ans.append(time[i]+time[j])
print(min(ans))

Solution (Python):
p, q, r = [int(_) for _ in input().split(' ')]
print(p + q + r - max(p, q, r))

Solution (Python):
inpl = lambda: list(map(int,input().split()))
P, Q, R = sorted(inpl())
print(P+Q)

Solution (Python):
p, q, r = map(int,input().split())

if p<=r :
    if q<=r:
        print(p+q)
    else:
        print(p+r)
elif p>r:
    if q<=p:
        print(r+q)
    else:
        print(p+r)

Solution (Python):
from collections import defaultdict,deque
import sys,heapq,bisect,math,itertools,string,queue,datetime
sys.setrecursionlimit(10**8)
INF = float('inf')
mod = 10**9 + 7
eps = 10**-7
def inp(): return int(sys.stdin.readline())
def inpl(): return list(map(int, sys.stdin.readline().split()))
def inpl_str(): return list(sys.stdin.readline().split())

P,Q,R = inpl()

print(P+Q+R-max(P,Q,R))

Solution (Python):
P,Q,R = map(int,input().split())

Ans1 = P + Q
Ans2 = Q + R
Ans3 = R + P

if(Ans1 > Ans2):
	Ans1 = Ans2

if(Ans1 > Ans3):
	Ans1 = Ans3

print (Ans1)

Solution (Python):
import sys
data = sys.stdin.readlines()
inputs = [int(x) for x in data[0].split()]
inputs.sort()
print(inputs[0] + inputs[1])

Solution (Python):
times = list(map(int, input().split()))

times.sort()

print(times[0] + times[1])

Solution (Python):
P,Q,R = map(int, input().split())

print(min(P+Q, P+R, Q+R))

Solution (Python):
from sys import stdin
l = stdin.readline().rstrip().split()
l.sort()
saitan = int(l[0]) + int(l[1])
print(saitan)

Solution (Python):
l = list(map(int,input().split()))
l.sort()
print(sum(l[:2]))

Solution (Python):
p,q,r = map(int, input().split())
print(min(p+q, q+r, p+r))

Solution (Python):
P, Q, R = map(int, input().split())
x = P+Q
y = Q+R
z = R+P
print(min(x, y, z))

Solution (Python):
li = list(map(int, input().split()))
m = min(li)
li.remove(m)
print(m + min(li))

Solution (Python):
dist = list(map(int,input().split()))

m = max(dist)
dist.remove(m)


print(sum(dist))

Solution (Python):
print(sum(sorted(map(int,input().split()))[:2]))

Solution (Python):
a,b,c = map(int,raw_input().split())
print min(a+b,a+c,b+c)

Solution (Python):
F, S, T = map(int, input().split())
FS = F + S
ST = S + T
TF = T + F
L = [FS, ST, TF]
print(min(L))

Solution (Python):
p,q,r=map(int,input().split())
A=p+q
B=q+r
C=p+r
print(min(A,B,C))

Solution (Python):
p, q, r = map(int, input().split())
print(min(p+q, q+r, r+p))

Solution (Python):
p,q,r = map(int,input().split())
sum = p + q + r - max([p,q,r])
print(sum)

Solution (Python):
p,q,r=map(int,input().split())
if p>=q and p>=r:
    print(q+r)
elif q>=p and q>=r:
    print(p+r)
else :print(q+p)

Solution (Python):
P, Q, R = [int(elem) for elem in input().split()]

print(P + Q + R - max(P, Q, R))

Solution (Python):
l = list(map(int, input().split()))
l.sort()
print(l[0]+l[1])

Solution (Python):
a=list(map(int,input().split()))
b= sorted(a)
print(b[0]+b[1])

Solution (Python):
a,b,c = map(int, raw_input().split())
if a >=b and a>=c:
  print b+c
elif b>=a and b>=c:
  print a+c
else:
  print a+b

Solution (Python):
p,q,r=map(int,input().split())

d=p+q
e=q+r
f=r+p
if d>f and e>f:
    print(f)
elif f>d and e>d:
    print(d)
elif f>e and d>e:
    print(e)
elif d==e or f==d:
    print(d)
elif e==f:
    print(e)

Solution (Python):
P, Q, R = map(int, input().split())
 
X = max([P, Q, R])
 
print(P + Q + R - X)

Solution (Python):
print(sum(sorted(list(map(int, input().split())))[:-1]))

Solution (Python):
P, Q, R = map(int, input().split())
s = P+Q+R
print(s-max(P,Q,R))

Solution (Python):
P,Q,R=map(int, input().split())
PQ=P+Q
PR=P+R
QR=Q+R
QP=Q+P
RP=R+P
RQ=R+Q
print(min(PQ,QR,QR,QP,RP,RQ))

Solution (Python):
p=list(map(int,input().split()))
p.sort()
print(p[0]+p[1])

Solution (Python):
p,q,r = map(int,input().split())
ans = [p,q,r]
ans.sort()
print(ans[0]+ans[1])

Solution (Python):
a, b, c= (int(i) for i in input().split()) 

if a >= b and a >= c:
    print(b + c)
elif b >= a and b >= c:
    print(a + c)
else:
    print(a + b)

Solution (Python):
p,q,r = map(int,input().split())
print(min(p+q,r+q,p+r))

Solution (Python):




p, q, r = map(int, input().split())


if p>=q and r>=q:
	a=q
	if p>r:
		b=r
	else:
		b=p

elif q>=p and r>=p:
	a=p
	if q>r:
		b=r
	else:
		b=q
		
else:
	a=r
	if q>p:
		b=p
	else:
		b=q



print("{}".format(a+b))

Solution (Python):
import copy

params = list(map(int, input().split()))
count = len(params)

minTime = 500

for i in range(count):
  pattern = copy.copy(params)
  total = 0
  pattern.pop(i)
  for j in range(len(pattern)):
      total = params[i]+pattern[j]
      if total <= minTime:
          minTime = total

print(minTime)

Solution (Python):
l=list(map(int,input().split()))
l.sort()
print(l[0]+l[1])

Solution (Python):
if __name__ == '__main__':
    P = [int(i) for i in input().split()]
    min = P[0] + P[1]
    for n, i in enumerate(P):
        for m, j in enumerate(P):
            if n != m and min > i + j:
                min = i + j
    print(min)

Solution (Python):


place = ['a','b','c']
time = list(map(int, input().split()))
dict = dict(zip(place,time))
time_list = []
for k1, v1 in dict.items():
        for k2, v2 in dict.items():
                if k1 != k2:
                        time_list.append(v1+v2)
print(min(time_list))

Solution (Python):
t=list(map(int,input().split()))
t.sort()

print(t[0]+t[1])

Solution (Python):

if __name__=='__main__':
    P,Q,R = map(int,input().split())
    if P <= R and Q <= R:
        print(P+Q)
    elif P <= Q:
        print(P+R)
    else:
        print(Q+R)

Solution (Python):
P,Q,R = list(map(int,input().split()))

time_list = [P+Q,Q+R,R+P]

print(min(time_list))

Solution (Python):
p,q,r = (int(x) for x in input().split())

print(min([p+q, q+r, r+p]))

Solution (Python):
x,y,z = map(int, input().split())
xy = x + y
yz = y + z
zx = x + z
print(min([xy,yz,zx]))

Solution (Python):
times = list(map(int,input().split()))
times.sort()

print(sum(times[:2]))

Solution (Python):

p, q, r = map(int, input().split())
print(p + q + r - max([ p, q, r ]))

Solution (Python):
from sys import stdin
def main():
    P, Q, R = map(int, stdin.readline().rstrip().split())
    
    maxRoot = max([P,Q,R])
    
    print(P+Q+R-maxRoot)

input = lambda: stdin.readline()
main()

Solution (Python):
p, q, r = map(int, input().split())

pqr_list = [p, q, r]

pqr_list.sort(reverse=True)

ans=0
ans+=pqr_list.pop()
ans+=pqr_list.pop()

print(ans)

Solution (Python):
P, Q, R = map(int, input().split())

x = [P + Q, Q + R, P + R]
print(min(x))

Solution (Python):
P, Q, R = map(int, input().split())

print(min(P+Q, P+R, Q+R))

Solution (Python):
a,b,c=input().split()
a=int(a)
b=int(b)
c=int(c)
if a+b <= a+c and a+b <= b+c:
    print(a+b)
elif a+c <= a+b and a+c <= b+c:
    print(a+c)
else:
    print(b+c)

Solution (Python):


 
input_dis = input()
distance = input_dis.split(" ")
 
minum_dis = 100000000
 
cal_dis1 = int(distance[0]) + int(distance[1])
cal_dis2 = int(distance[2]) + int(distance[0])
cal_dis3 = int(distance[2]) + int(distance[1])
 
if cal_dis1 < minum_dis:
    minum_dis = cal_dis1
if cal_dis2 < minum_dis:
    minum_dis = cal_dis2
if cal_dis3 < minum_dis:
    minum_dis = cal_dis3
    
print(minum_dis)

Solution (Python):
PQR = [int(x) for x in input().split()]
PQR.sort()
answer = PQR[0] + PQR[1]
print(answer)

Solution (Python):
W = [int(i) for i in input().split()]
print(sum(W) - max(W))

Solution (Python):
pqr = list(map(int, input().split()))

ans = 200
for index, i in enumerate(pqr):
    ans = min(ans, i + pqr[(index + 1) % 3])

print(ans)

Solution (Python):
P, Q, R = map(int, input().split())


print(sum([P, Q, R]) - max([P, Q, R]))

Solution (Python):
P, Q, R =map(int, input().split( ))

res=[P+Q,P+R,Q+R]
res.sort()
print(res[0])

Solution (Python):
PQR = list(map(int, input().split()))

PQR.sort()

print(PQR[0] + PQR[1])

Solution (Python):

def IL(): return list(map(int,input().split()))
def SL(): return input().split()
def I(): return int(input())
def S(): return list(input())
A=IL()
A.sort()
print(A[0]+A[1])

Solution (Python):
a = [int(x) for x in input().split()]
p,q,r = a[0], a[1], a[2]
print(sum(sorted(a)[0:2]))

Solution (Python):






N = list(map(int, input().split()))

a = N[0] + N[1]
b = N[1] + N[2]
c = N[2] + N[0]

ans = min(min(a, b), c)

print(ans)

Solution (Python):
pqr =input().split()
pqr = [int(pqr[i]) for i in range(3)]
pqr.sort()
t = pqr[0]+pqr[1]
print(t)

Solution (Python):
times = sorted(list(map(int,input().split())))
ans = times[0]+times[1]
print(ans)

Solution (Python):
P,Q,R = map(int, input().split())
S = []
S.append(P+Q)
S.append(Q+R)
S.append(R+P)

print(min(S))

Solution (Python):
p = list(map(int,input().split(' ')))
p.sort()
print(p[0]+p[1])

Solution (Python):
p, q, r = map(int, input().split())
print(min(min(p+q, q+r), p+r))

Solution (Python):
l = list(map(int, input().split()))
print(min([sum(l) - l[i] for i in range(len(l))]))

Solution (Python):
p,q,r=map(int,input().split())
n=[p+q,q+r,r+p,2*r+p,2*p+q,2*q+r,2*p+r,2*r+q,2*q+p]
ns=sorted(n)
print(ns[0])

Solution (Python):
P, Q, R = map(int,input().split())
print(min(P + Q, Q+R, R + P))

Solution (Python):
import sys
from itertools import combinations

distances = [int(x) for x in sys.stdin.readline().split(' ')]
print(min([sum(x) for x in combinations(distances, 2)]))

Solution (Python):
T = input()
data = T.split()
data_int = list(map(int, data))
data_int.sort()
print(data_int[0] + data_int[1])

Solution (Python):
x= list(map(int,input().split()))
print(sum(x)-max(x))

Solution (Python):
def main():
    p, q, r = map(int, input().split())
    ans = [p + q, p + r, q + r]
    print(min(ans))


if __name__ == '__main__':
    main()

Solution (Python):
P,Q,R =  list(map(int,input().split()))

min=P+Q


if(P+Q > Q+R):
    min = Q+R
    
    if(Q+R > P+R):
        min = P+R

if(P+Q > P+R):
    min = P+R
    
    if(P+R > Q+R):
        min = Q+R

print(min)

Solution (Python):
p,q,r = map(int,input().split())

test = []
test.append(p+q)
test.append(q+r)
test.append(p+r)

print(min(test))

Solution (Python):
P,Q,R = (int(i) for i in input().split())

N = max(P,Q,R)

print(P+Q+R-N)

Solution (Python):
import numpy as np

P,Q,R = (int(x) for x in input().split())

times = []

times.append(P+Q)
times.append(P+R)
times.append(Q+R)

print(min(times))

Solution (Python):
P, Q, R = (int(i) for i in input().split())
print(min(P+Q, Q+R, R+P))

Solution (Python):
p,q,r = map(int,input().split())
print(min(p+q,p+r,q+r))

Solution (Python):
t_list=[]
is_arg_ok = False
try:
  t_list = [int(n) for n in input().split(' ')]
except:
  print('age,price must be numbers')
  sys.exit(1)

min_1 = 10000
min_2 = 10000
for i in range(len(t_list)):
    t1 = t_list[i]
    if min_1 > t1:
        min_2 = min_1
        min_1 = t1
    elif min_2 > t1:
        min_2 = t1
min_t = min_1 + min_2
print(min_t)

Solution (Python):
def smaller(x, y):
	if x < y: return x
	return y

P, Q, R = map(int, input().split())

r1 = P + Q
r2 = Q + R
r3 = R + P

print(smaller(r1, smaller(r2, r3)))

Solution (Python):
pqr = list(map(int, input().split()))
print(sum(pqr)-max(pqr))