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



Sample input:
1 3 4


Sample output:
4

Submission status: Accepted

Solution code:
from sys import stdin

t = [int(x) for x in stdin.readline().rstrip().split()]
t.remove(max(t))
print(sum(t))

Submission status: Accepted

Solution code:
stdin = input().split(" ")
P = int(stdin[0])
Q = int(stdin[1])
R = int(stdin[2])

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

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-

P,Q,R = list(map(int, input().rstrip().split()))
#-----

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a,b,c=map(int,input().split())
d=int(a+b)
e=int(a+c)
f=int(b+c)

print(min(d,e,f))

Submission status: Accepted

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

lis.sort()

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

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
#129_A
a=sorted(list(map(int,input().split())))
print(sum(a)-max(a))

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
x = list(map(int, input().split()))
x = sorted(x)
print(x[0]+x[1])

Submission status: Accepted

Solution code:
P=list(map(int,input().split()))

Q=sorted(P)

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

Submission status: Accepted

Solution code:
li = list(map(int,input().split()))
li.sort()
ans = 0
for i in range(2):
    ans = ans + li[i]
else:
    print(ans)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

print(sum(pqr) - max(pqr))

Submission status: Accepted

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

Submission status: Accepted

Solution code:
#!/usr/bin/python3
# -*- coding:utf-8 -*-

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

if __name__=='__main__':
  main()

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
p = list(map(int,input().split()))

mn = 200
for i in range(2):
    for j in range(i+1,3):
        if (p[i]+p[j] < mn):
            mn = p[i]+p[j]

print(mn)

Submission status: Accepted

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

Submission status: Accepted

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

x = [p+q,q+r,r+p]

print(min(x))

Submission status: Accepted

Solution code:
number = input().split(" ")
P = int(number[0])
Q = int(number[1])
R = int(number[2])
ans = []
ans.append(int(P+Q))
ans.append(int(P+R))
ans.append(int(Q+R))
ans.sort()
print(ans[0])

Submission status: Accepted

Solution code:
P, Q, R = map(int,input().split())
 
PQ = P + Q
QR = Q + R
RP = R + P

temp1 = min(PQ, QR)
temp2 = min(temp1, RP)

print(temp2)

Submission status: Accepted

Solution code:
# Code for A - Airplane
# Use input() to fetch data from STDIN
[p, q, r] = [int(x) for x in input().split()]

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

Submission status: Accepted

Solution code:
import itertools
lst = list(map(int, input().split()))
ans = float("INF")

for i in itertools.combinations(lst, 2):
    ans = min(ans, sum(i))

print(ans)

Submission status: Accepted

Solution code:
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians
from itertools import accumulate, permutations, combinations, product
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from bisect import bisect, bisect_left
from fractions import gcd
from heapq import heappush, heappop
from functools import reduce

def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

s = sorted(LIST())
print(s[0]+s[1])

Submission status: Accepted

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

Submission status: Accepted

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

a = p+q
b = p+r
c = r+q

print(min(a, b, c))

Submission status: Accepted

Solution code:
S=list(map(int,input().split()))
min=10**4
for i in range(3):
    time=sum(S)-S[i]
    if time<min:
        min=time
print(min)

Submission status: Accepted

Solution code:
import itertools
a=list(map(int,input().split()))
k=[]
for v in itertools.combinations(a,2):
    k.append(v[0]+v[1])
print(min(k))

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
p, q, r = map(int, input().split())
s = sorted([p, q, r])
print(s[0] + s[1])

Submission status: Accepted

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

Submission status: Accepted

Solution code:
P, Q, R = (int(pqr) for pqr in input().split())
print(min([P+Q, R+P, Q+R]))

Submission status: Accepted

Solution code:
P, Q, R = map(int,input().split())
list = [P + Q, Q + R, R + P]
list.sort(reverse=False)

print(list[0])

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
# https://atcoder.jp/contests/abc129/tasks/abc129_a

import itertools
d = [int(x) for x in input().split()]
li = []
for t1, t2 in itertools.permutations(d, 2):
    li.append(t1 + t2)
print(min(li))

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys

p, q, r = map(int, sys.stdin.readline().split())

def main():
    tot = p + q + r
    return tot - max(p, q, r)

if __name__ == '__main__':
    ans = main()
    print(ans)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
pqr = sorted([int(i) for i in input().split()])
print (sum(pqr[:2]))

Submission status: Accepted

Solution code:
P, Q, R = [int(s) for s in input().split(' ')]
print(min(P + Q, Q + R, R + P))

Submission status: Accepted

Solution code:
# coding: utf-8
# Your code here!
l = list(map(int, input().split(' ')))
print(sum(l) - max(l))

Submission status: Accepted

Solution code:
import os, sys, re, math

(P, Q, R) = [int(n) for n in input().split()]

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
p, q, r = map(int, input().split())
print(sum(sorted([p, q, r])[:2]))

Submission status: Accepted

Solution code:
# import numpy as np
s = list(map(int,input().split()))
# l = np.array(s)
max_value = max(s)
max_i = s.index(max_value)
s.pop(max_i)
print(sum(s))

Submission status: Accepted

Solution code:
s = list(map(int, input().split()))
s.sort()
print(sum(s[0:2]))

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
# -*- coding: utf-8 -*-


def main():
    PQR = list(map(int, input().split()))
    PQR.sort()
    print(sum(PQR[:2]))


if __name__ == "__main__":
    main()

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
l = list(map(int, input().split()))
l.sort()
l.pop(-1)
print(sum(l))

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
P, Q, R = list(map(int, input().split()))
x = [P, Q, R]
maxvalue = 0
for i in range(len(x)):
    if x[i] > maxvalue:
        maxvalue = x[i]
print(P + Q + R - maxvalue)

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

if max(p,q,r) == p:
    print(q + r)
elif max(p,q,r) == q:
    print(r + p)
else:
    print(p + q)

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
m = list(map(int, input().split()))

    # 解法1 sort
#    print(sorted(m)[0] + sorted(m)[1])
    # 解法2 max
#    print(sum(l)-max(m)) # maxの使用
    # 解法3 heapq  https://note.nkmk.me/python-max-min-heapq-nlargest-nsmallest/
import heapq
print(sum(heapq.nsmallest(2, m)))

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a,b,c=map(int,input().split())

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a,b,c = list(map(int, input().split(' ')))

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n = list(map(int,input().split()))

n.sort()

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

Submission status: Accepted

Solution code:
def main():
    a, b, c = map(int, input().split())

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

if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
#129 a
p,q,r=map(int,input().split())
a=p+q
b=q+r
c=r+p
ans=min(a,b,c)
print(ans)

Submission status: Accepted

Solution code:
Planetime=list(map(int,input().split()))
Planetime.sort()

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

Submission status: Accepted

Solution code:
a = [i for i in map(int, input().split())]
print(sum(a)-max(a))

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a, b, c = map( int, input().split())

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
def LI():
  return [int(s) for s in input().split()]

S = sorted(LI())

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
dist = [int(i) for i in input().split()]

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

Submission status: Accepted

Solution code:
import sys

stdin = sys.stdin

mod = 1000000007

ni = lambda: int(ns())
na = lambda: list(map(int, stdin.readline().split()))
ns = lambda: stdin.readline().rstrip()
nas = lambda: stdin.readline().split()

m = na()
m.sort()
print(m[0] + m[1])

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys

num = list(map(int,input().split()))
P = num[0]
Q = num[1]
R = num[2]
num.sort()
print(num[0]+num[1])

Submission status: Accepted

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

Submission status: Accepted

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

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

print(min(time))

Submission status: Accepted

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

Submission status: Accepted

Solution code:
A,B,C=map(int,input().split())

print(min(B+C,A+C,A+B))

Submission status: Accepted

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

Submission status: Accepted

Solution code:
A,B,C = map(int, input().split())
smallABC = [A+B, A+C, B+C ]
print(min(smallABC))

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import itertools
s=list(map(int, input().split()))
a=list(itertools.permutations(s,2))
b=list()
for i in range(len(a)):
    b.append(sum(a[i]))
print(min(b))

Submission status: Accepted

Solution code:
ab,bc,ac=map(int,input().split())
print(min(ab+bc, ab+ac, bc+ac))

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

list_ = [p, q, r]
list_ = sorted(list_)

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

Submission status: Accepted

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

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

Submission status: Accepted

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

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

print(ans)

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
#python3
a=[int(i) for i in input().split()]
s=sum(a)
ans=int(1e9)
for i in a:
  ans = min(s-i, ans)
print(ans)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
"""
author : halo2halo
date : 9, Jan, 2020
"""

import sys

# import numpy as np
import itertools

read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines
sys.setrecursionlimit(10 ** 7)

P = [int(i) for i in read().split()]
ans=sum(P)
for i in itertools.combinations(P,len(P)-1):
    ans=min(ans,sum(i))

print(ans)

Submission status: Accepted

Solution code:
"""
author : halo2halo
date : 9, Jan, 2020
"""

import sys

# import numpy as np
import itertools

read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines
sys.setrecursionlimit(10 ** 7)

P = [int(i) for i in read().split()]
P.sort()
print(sum(P[:len(P)-1]))

Submission status: Accepted

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

print(sum(l) - max(l))

Submission status: Accepted

Solution code:
l=list(map(int,input().split()))
t=sorted(l)

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

Submission status: Accepted

Solution code:
import sys
def input(): return sys.stdin.readline().rstrip()

def main():
    pqr = sorted(map(int, input().split()))
    print(sum(pqr[:-1]))

if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
import sys
def input(): return sys.stdin.readline().rstrip()

def main():
    p, q, r = map(int, input().split())
    m = max([p, q, r])
    if m == p:
        print(q + r)
    elif m == q:
        print(p + r)
    elif m == r:
        print(p + q)

if __name__ == '__main__':
    main()

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
p,q,r=(int(i) for i in input().split())
print(min(p+q,p+r,q+r))

Submission status: Accepted

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

Submission status: Accepted

Solution code:
time = sorted(list(map(int, input().split())))
print(time[0]+time[1])

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
rList = sorted(list(map(int,input().split())))

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

Submission status: Accepted

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


if __name__ == '__main__':
    main()

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
o = input()
o_list = o.split(" ")
o_list_i = [int(s) for s in o_list]
o_list_i.sort()

o0 = int(o_list_i[0])
o1 = int(o_list_i[1])
print( o0 + o1 )

Submission status: Accepted

Solution code:
o = input()
o_list = o.split(" ")

p = int(o_list[0])
q = int(o_list[1])
r = int(o_list[2])
pq = p + q
qr = q + r
rp = r + p

if pq <= qr and pq <= rp:
    print(pq)
elif qr <= rp and qr <= pq:
    print(qr)
elif rp <= pq and rp <= qr:
    print(rp)

Submission status: Accepted

Solution code:
INT = lambda: int(input())
INTM = lambda: map(int,input().split())
STRM = lambda: map(str,input().split())
STR = lambda: str(input())
LIST = lambda: list(map(int,input().split()))
LISTS = lambda: list(map(str,input().split()))
def do():
    p,q,r=INTM()
    print(min(p+q,q+r,r+p))
if __name__ == '__main__':
    do()

Submission status: Accepted

Solution code:
from itertools import product, permutations,combinations

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

print(
  min(
    map(lambda x: sum(x), combinations(nums,2))
  )
)

Submission status: Accepted

Solution code:
l=[int(i) for i in input().split()]
L=max(l)
l.remove(L)
print(sum(l))

Submission status: Accepted

Solution code:
air = list(map(int,input().split()))
air =sorted(air)
print(air[0]+air[1])

Submission status: Accepted

Solution code:
from sys import stdin
import sys
import numpy as np
##  input functions for me
def ria(sep = ''):
    if sep == '' :
        return list(map(int, input().split())) 
    else: return list(map(int, input().split(sep)))
def rsa(sep = ''):
    if sep == '' :
        return input().split() 
    else: return input().split(sep)
def ri(): return int(input())
def rd(): return float(input())
def rs(): return input()
##
def main():
    P, Q, R = map(int, input().split())
    print(np.min([P + Q, Q + R, R + P]))
    


if __name__ == "__main__":
    main()

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a, b, c = map(int, open(0).read().split())
print(sum(sorted([a, b, c])[:-1]))

Submission status: Accepted

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

total = p + q + r

a = max(p, q, r)

print(total - a)

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
print(sum(sorted([int(i) for i in input().split(" ")])[:2]))

Submission status: Accepted

Solution code:

P, Q, R = [int(i) for i in input().split()]

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

Submission status: Accepted

Solution code:
def main():
    time_list = list(map(int, input().split()))
    ans = 0
    for _ in range(2):
        i = time_list.index(min(time_list))
        ans += time_list.pop(i)
    return ans
if __name__ == '__main__':
    print(main())

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
def main():

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

if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
# coding: utf-8
# Your code here!
P,Q,R=map(int,input().split())

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

Submission status: Accepted

Solution code:
p = list(map(int, input().split()))
k = max(p)
sum = p[0]+p[1]+p[2]-k
print(sum)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
a, b, c = map(int, input().split())

print(a+b+c - max(a, b, c))

Submission status: Accepted

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

a = sorted([P,Q,R])

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

Submission status: Accepted

Solution code:
import itertools

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

combos = itertools.combinations(routes,2)

time = []
for c in combos:
    time.append(c[0] + c[1])
    
print(min(time))

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
#!/usr/bin/env python3

import sys
import math
from bisect import bisect_right as br
from bisect import bisect_left as bl
sys.setrecursionlimit(1000000)
from heapq import heappush, heappop,heappushpop
from collections import defaultdict
from itertools import accumulate
from collections import Counter
from collections import deque
from operator import itemgetter
from itertools import permutations
mod = 10**9 + 7
inf = float('inf')
def I(): return int(sys.stdin.readline())
def LI(): return list(map(int,sys.stdin.readline().split()))

p,q,r = LI()

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

Submission status: Accepted

Solution code:
a,b,c=map(int,input().split())

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

Submission status: Accepted

Solution code:
T = list(map(int, input().split()))

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

Submission status: Accepted

Solution code:
S = [ int(x) for x in input().split() ]
print( sum( S ) - max( S ) )

Submission status: Accepted

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

t = sorted(time)

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

Submission status: Accepted

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

Submission status: Accepted

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

if p+q <= p+r and p+q <= q+r:
    print(p+q)

elif q+r <= p+q and q+r <= p+r:
    print(q+r)

elif p+r <= p+q and p+r <= q+r:
    print(p+r)

Submission status: Accepted

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

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

print(ans)

Submission status: Accepted

Solution code:
a,b,c=map(int,input().split())
A=[a,b,c]
print(sum(A)-max(A))

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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


if __name__ == '__main__':
    solve()

Submission status: Accepted

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


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

Submission status: Accepted

Solution code:
import itertools
print(min([x + y for x, y in itertools.permutations([int(x) for x in input().split()], 2)]))

Submission status: Accepted

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

print(sum(sorted([P, Q, R])[:2]))

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
P, Q, R = [int(i) for i in input().split()]
# P, Q, R = map(int, input().split())
# print(min(P+Q, Q+R, R+P))
min_time = 200
for num in [P+Q, Q+R, R+P]:
    if num < min_time:
        min_time = num
print(min_time)

Submission status: Accepted

Solution code:
P, Q, R = [int(i) for i in input().split()]
# P, Q, R = map(int, input().split())
print(min(P+Q, Q+R, R+P))

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:

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

a.sort()

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

Submission status: Accepted

Solution code:
p,q,r = [int(x) for x in input().split()]
print(min(p+q, q+r, r+p))

Submission status: Accepted

Solution code:
P,Q,R = map(int,input().split())
PQ = P + Q
QR = Q + R
RP = R + P
tmp = PQ
if tmp>QR: tmp=QR
if tmp>RP: tmp=RP
print(tmp)

Submission status: Accepted

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

a.sort()

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

Submission status: Accepted

Solution code:
k=list(map(int,input().strip().split()))
k.remove(max(k))
print(sum(k))

Submission status: Accepted

Solution code:
a=[int(n) for n in input().split()]
a.sort()
print(a[0]+a[1])

Submission status: Accepted

Solution code:
# your code goes here
p,q,r = map(int,input().split())
print(min(p+q,q+r,r+p))

Submission status: Accepted

Solution code:
import itertools

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

c = itertools.combinations([P, Q, R], 2)
ans = 10**9

for v in c:
  ans = min(ans, v[0] + v[1])

print(ans)

Submission status: Accepted

Solution code:
ls = sorted(list(map(int,input().split())))
print(sum(ls)-max(ls))

Submission status: Accepted

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

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

Submission status: Accepted

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

Submission status: Accepted

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

Submission status: Accepted

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

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

Submission status: Accepted

Solution code:
a,b,c = map(int, input().split())
x = 1000
if x > a+b:
    x = a+b
if x> b+c:
    x = b+c
if x> c+a:
    x = c+a
print(x)

Submission status: Accepted

Solution code:
A=list(map(int, input().split()))


newlist = sorted(A)

sum = newlist[0] + newlist[1]

print(sum)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
l=list(map(int,input().split()))
len_l=len(l)
ans=[]
for i in range(len_l):
    for j in range(len_l):
        if i!=j:
            ans.append(l[i]+l[j])
print(min(ans))

Submission status: Accepted

Solution code:
time = list(map(int, input().split()))
pqr = sorted(time)

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

Submission status: Accepted

Solution code:
p, q, r = map(int, input().split())
a = p + q
b = p + r
c = q + r
print(min(a, b, c))

Submission status: Accepted

Solution code:
p = list(map(int,input().split()))
pd = sorted(p, reverse=False)
print(pd[0]+pd[1])

Submission status: Accepted

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

Submission status: Accepted

Solution code:
p, q, r = map(int, input().split())
a1 = p + q
a2 = p + r
a3 = q + r
print(min(a1, a2, a3))

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# ABC-129-A
P, Q, R = map(int, input().split())
print(min(P+Q, Q+R, R+P))