#include<cstdio>
int main()
{
    int p,q,r;
    scanf("%d%d%d",&p,&q,&r);
    int sum1,sum2,sum3;
    sum1=p+q;
    sum2=p+r;
    sum3=q+r;
    int t;
    if(sum1>sum2)
    {
        t=sum2;
        sum1=t;
        sum2=sum1;
    }
    if(sum1>sum3)
    {
        t=sum3;
        sum1=t;
        sum3=sum1;
    }
    printf("%d\n",sum1);
    return 0;
}
